please dont rip this site
Home About Projects PIC code SX code
Here is some code converted from the PIC collection and some more SX specific routines.

Please send any questions or comments to golovchenko@mail.ru, or the PICList (with the topic tag [SX]: in the subject).

Routine Name Size, instructions Max timing, cycles Temporary registers Notes
Multiplication
24 by 24 bits 29 537 1
Division
8 by 8 bits to 24 bit floating point 41 449 1
16 by 8 bits with Q16.16 fixed point result 39 491 1
24 by 16 bits 28 632 3
32 by 16 bits using 16 by 16 bits with a 16 bit result 36 377 2/4
48 by 24 bits (and one using CARRYX option) 59/51 1558/1366 5
48 by 23 bits 52 1366 4
Divide 14 bit integer using a fixed point divisor and result (7Q8 format) 27 295 0
Square Root
24 bit floating point 85 438 6 IEEE<>Microchip format conversion
12 bit integer 32 124 3
8 bit 20 70 2
8 bit fast 29 31 1 See also a faster one for PICs
8 bit small 10 135 0
Routine Name Size, instructions Max timing, cycles Temporary registers Notes
CORDIC
Vector magnitude, 16 bits 147 ~1700/850 4
Radix Conversion
16 bit binary to 5 digit decimal 73 251 0 strips a digit at a time
5 digit decimal to 16 bit binary 35 40 0
5 digit decimal (BCD) to 16 bit binary 23 358 1
Miscellaneous
8 bit random number generator 11 11 0 my version at the bottom
Delay exactly N cycles - - 0 scalable for any N size; at the bottom of the page
Wait for RTCC overflow with zero jitter 11 - 0 Used in main code for time critical apps; no prescaler
Test code detecting video horizontal sync using the built-in comparator and software PLL
Routine Name Size, instructions Max timing, cycles Temporary registers Notes

: "
" +


file: /Techref/member/Ng--944/sx_collection.htm, 8KB, , updated: 2014/12/11 12:41, local time: 2024/11/26 16:49, owner: NG--944,
TOP NEW HELP FIND: 
3.16.82.182:LOG IN

 ©2024 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions?
Please DO link to this page! Digg it! / MAKE!

<A HREF="http://sxlist.com/Techref/member/Ng--944/sx_collection.htm"> SX Code Collection</A>

After you find an appropriate page, you are invited to your to this massmind site! (posts will be visible only to you before review) Just type a nice message (short messages are blocked as spam) in the box and press the Post button. (HTML welcomed, but not the <A tag: Instead, use the link box to link to another page. A tutorial is available Members can login to post directly, become page editors, and be credited for their posts.


Link? Put it here: 
if you want a response, please enter your email address: 
Attn spammers: All posts are reviewed before being made visible to anyone other than the poster.
Did you find what you needed?