Commit Graph

36 Commits

Author SHA1 Message Date
George Oikonomou
dd26accc07 We can now use SDCC's __nonbanked feature
This allows us to reduce CODE footprint of SDCC projects
built with --model-huge. Use carefully!

* Added a facility which allows us to enable/disable the
  feature from the CPU dir (CC_CONF_NON_BANKED_OPTIMIZATION)
* Added the CC_NON_BANKED keyword to some platform files
  (expands to __nonbanked)
* Started using this for some examples
2012-04-26 15:28:43 +01:00
George Oikonomou
6fb48174ba Fixed a documentation typo 2012-04-20 16:03:37 +01:00
David Kopf
cac4e9a222 Add clock_delay_us and clock_set_seconds to clock.h. Modify clock_wait to use clock_time_t.
Remove the troublesome avr/dev/delay.* files.
Add PLATFORM_NAME and combine the confusing *_REVISION defines into a single PLATFORM_TYPE
2012-04-09 15:49:53 -04:00
George Oikonomou
57969259ce cc2x3x clock_delay(len) now delays for approx. len usecs 2012-04-03 16:26:11 +01:00
George Oikonomou
3cb26adeda Added an ASM(foo) macro for cc243x 2012-04-03 16:26:11 +01:00
George Oikonomou
11a7f644ac Comment rewording and formatting 2012-04-03 16:26:10 +01:00
George Oikonomou
ce17fa131c Stack-friendly cc243x clock ISR enabled by default
This new approach (CLOCK_CONF_ACCURATE=0) was not as inaccurate
as originally thought. In fact, it has pretty much the same
accuracy as the old, stack-hungry version.

* Renamed the define from CLOCK_CONF_ACCURATE (1: old) to
  CLOCK_CONF_STACK_FRIENDLY (1: new) to stop implying
  that one is more accurate than the other.
* Using CLOCK_CONF_STACK_FRIENDLY by default.
2012-04-03 16:26:10 +01:00
George Oikonomou
924fe934c1 Deleted obsolete macros. Minor formatting 2012-04-03 16:26:10 +01:00
George Oikonomou
ffa3a1c4c3 cc2x3x clock driver cleanup
* Bit-Addressable SFRs are now accessed as such,
  instead of (N)OR-ing the byte
* A routine was declared as CCIF but not defined as such. Fixed
* Deleted a leftover duplicate define
* Formatting
* Comment updates and clarifications
2012-04-03 16:26:10 +01:00
George Oikonomou
5240519dd9 Renamed a config define to better match contiki's naming philosophy 2012-04-02 11:38:54 +01:00
George Oikonomou
bce34e4b9a For cc2x30, moved CLOCK_CONF_SENCOND to the cpu dir.
The value is not really configurable by the platform so having it
in contiki-conf.h didn't make huge sense.
2012-04-02 11:22:19 +01:00
George Oikonomou
d958ee3125 Deleted the old Sensinode 'read mac from flash' routine.
Since the introduction of a purpose-written routine, the old
generic one (which was written in asm) was never being used.
There was a configuration directive which allowed us to switch
between the two. All references to this configuration directive
have also been removed.
2012-04-02 11:21:32 +01:00
George Oikonomou
5d8f63a61b We've not been using the cc2430 converter for a while now 2012-04-02 11:03:49 +01:00
George Oikonomou
7854ee499a Wrapped cc2x30 SOFT_RESET() macro inside do {...} while(0) 2012-03-29 13:11:04 +01:00
George Oikonomou
4f1e251603 Some uN_t had crept back in cc2530dk and sensinode.
Changed to uintN_t plus a bit of code formatting
2012-03-29 13:10:10 +01:00
George Oikonomou
b7674c3636 Reincarnate the sensinode/cc2430 port 2012-03-23 14:41:07 +00:00
Nicholas J Humfrey
1cda3da17e Converted u8_t to uint8_t and u16_t to uint16_t in the cpu directory. 2012-02-21 08:33:24 -05:00
adamdunkels
5585d72c86 A simple but substantial change: uIP used the htons()/HTONS() macro
functions for converting between host and network byte order. These
names are the de facto standard names for this functionality because
of the original BSD TCP/IP implementation. But they cause problems for
uIP/Contiki: some platforms define these names themselves (Mac OS,
most notably), causing compilation problems for Contiki on those
platforms.

This commit changes all htons to uip_htons instead. Same goes for
htonl, ntohs, and ntohl. All-caps versions as well.
2010-10-19 18:29:03 +00:00
adamdunkels
3fa8ffda1a Moved the modules packetbuf, queuebuf, and packetqueue from net/rime to net/, since they are not Rime-specific 2010-06-14 19:19:16 +00:00
anthony-a
04fb6e5b42 initial add. 2010-04-10 21:18:32 +00:00
anthony-a
3de90a9671 fix adc compile errors when HAVE_DMA is not true.
remove reference to brione_lcd.h
turn off DEBUG messages.
2010-04-10 19:59:37 +00:00
anthony-a
76749a382d move cc2430_process to home bank since it needs to be called from a function pointer.
disable led code to make room in home bank.
2010-01-29 19:15:44 +00:00
anthony-a
507460d29a update code bank assignments 2010-01-29 19:13:00 +00:00
anthony-a
dbdf9982a9 change bank assignments.
add missing header file.
add ihx converter
2010-01-26 02:37:51 +00:00
anthony-a
1427c79b7a include new files in source file list. 2010-01-25 23:24:03 +00:00
anthony-a
6280cea706 remove bank macros which are now in banked.h 2010-01-25 23:13:04 +00:00
anthony-a
9cfe29612a Modifications to support banked code. Interrupts and routines accessed through function pointers reside in independent files so they can be assigned to the HOME bank. Init code can be placed in any bank.
Also add adc init code and bank header files.
2010-01-25 23:12:09 +00:00
anthony-a
742c5a0782 add definition for PSBANK used in sdcc crtbank.asm 2010-01-21 15:37:18 +00:00
anthony-a
acc1fe923c rules file for assigning code files to specific banks. 2010-01-21 15:34:26 +00:00
anthony-a
2f853dc930 Add support for bank switching and segment.rules file to assign code to banks. 2010-01-21 15:33:19 +00:00
zdshelby
c5ecde4ca0 Fixes and improvements from Anthony Asterisk
- First in 8051def.h,  it appears the uip_arch-asm.S file was copied from z80 and am unsure it will work properly.  I modified the 8051def.h to prevent the UIP code from using these routines.
- In dma.c the config routine provides access to all of the DMA channel options, except for the word mode flag.  In order to maintain compatibility with any existing code I created a second routine and converted the original routine into a wrapper routine with a fixed word mode value.
- uart.c::uart0_init was missing blocking access to the higher baud rates.  I am not sure why, so I corrected this.
- I also copied over to header files that provide some useful macros from the msp430 cpu.  The files are lpm.h and hwconf.h.  The lpm.h is for switching power modes, I think.  The hwconf.h has various macros for configuring port I/O.  By porting these files the led/button api's can be ported with minimal modifications.
2009-12-22 09:28:14 +00:00
zdshelby
c89b700631 - Fixed the MAC/RF interface problems, now correctly working with sicslowmac. Tested with rf_test_tx and rf_test_rx. Still needs more thorough testing.
- Corrected a Makefile bug, was complaining about *.d missing
2009-10-15 12:43:53 +00:00
zdshelby
44a8bc056f - Added mtarch.c and mtarch.h back to /cpu/cc2430. Seems that mt.c needs mtarch.h even though we are not using mtarch right now in this port. 2009-09-29 14:38:51 +00:00
zdshelby
d98026ae03 - Added RF address setup function (byte order may not be correct)
- Fixed the interrupt and read functions, now receiving one frame correctly
- Improved the send and read functions to work with sicslowmac.c
- TODO: Still a MAC interaction problem. Although the exact same payload is received and sent up to the MAC as is sent, the MAC doesn't do anything with it. Turn on DEBUG in sicslowmac.c to see the problem.
- Removed mtarch files, not used currently
2009-09-11 08:07:12 +00:00
zdshelby
4a14db6d3a - Fixed a compilation problem caused by 2.3 root Makefile-include changes with regard to sdcc.
- Fixed a small typo in cc2430_rf.c
- examples/sensinode now compiles
2009-09-09 07:32:02 +00:00
zdshelby
c9954072c9 Initial commit of cc2430 cpu port files. Currently used by /platform/sensinode. 2009-09-08 20:07:35 +00:00