[Tinyos-2-commits] CVS: tinyos-2.x/tos/chips/cc2420/transmit CC2420TransmitP.nc, 1.9, 1.10
kusy
kusy at users.sourceforge.net
Wed Aug 6 17:06:55 PDT 2008
- Previous message: [Tinyos-2-commits] CVS: tinyos-2.x/tools/release build-rpms, 1.7, 1.8 tinyos-tools.files, 1.4, 1.5 tinyos-tools.spec, 1.6, 1.7 tinyos.files, 1.7, 1.8 tinyos.spec, 1.7, 1.8
- Next message: [Tinyos-2-commits] CVS: tinyos-2.x/tools/release deputy.spec, NONE, 1.1
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/tinyos/tinyos-2.x/tos/chips/cc2420/transmit
In directory sc8-pr-cvs10.sourceforge.net:/tmp/cvs-serv26931
Modified Files:
CC2420TransmitP.nc
Log Message:
Previously reported timestamping bug was only fixed partially: *timesync was computed correctly, but could be written at the wrong offset with TXFIFO_RAM.write (this would only happen if cc2420 was not the longest header). Bug fixed here.
Index: CC2420TransmitP.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/chips/cc2420/transmit/CC2420TransmitP.nc,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** CC2420TransmitP.nc 11 Jul 2008 19:21:23 -0000 1.9
--- CC2420TransmitP.nc 7 Aug 2008 00:06:53 -0000 1.10
***************
*** 269,278 ****
call PacketTimeStamp.set(m_msg, time32);
if (call PacketTimeSyncOffset.isSet(m_msg)) {
! nx_uint8_t *taddr = m_msg->data + (call PacketTimeSyncOffset.get(m_msg) - sizeof(cc2420_header_t));
! timesync_radio_t *timesync = (timesync_radio_t*)taddr;
// set timesync event time as the offset between the event time and the SFD interrupt time (TEP 133)
*timesync -= time32;
call CSN.clr();
! call TXFIFO_RAM.write( call PacketTimeSyncOffset.get(m_msg), (uint8_t*)timesync, sizeof(timesync_radio_t) );
call CSN.set();
}
--- 269,278 ----
call PacketTimeStamp.set(m_msg, time32);
if (call PacketTimeSyncOffset.isSet(m_msg)) {
! uint8_t absOffset = sizeof(message_header_t)-sizeof(cc2420_header_t)+call PacketTimeSyncOffset.get(m_msg);
! timesync_radio_t *timesync = (timesync_radio_t *)((nx_uint8_t*)m_msg+absOffset);
// set timesync event time as the offset between the event time and the SFD interrupt time (TEP 133)
*timesync -= time32;
call CSN.clr();
! call TXFIFO_RAM.write( absOffset, (uint8_t*)timesync, sizeof(timesync_radio_t) );
call CSN.set();
}
- Previous message: [Tinyos-2-commits] CVS: tinyos-2.x/tools/release build-rpms, 1.7, 1.8 tinyos-tools.files, 1.4, 1.5 tinyos-tools.spec, 1.6, 1.7 tinyos.files, 1.7, 1.8 tinyos.spec, 1.7, 1.8
- Next message: [Tinyos-2-commits] CVS: tinyos-2.x/tools/release deputy.spec, NONE, 1.1
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the Tinyos-2-commits
mailing list