File tree Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ extern "C" {
2626/** Tick Counter united by ms */
2727static volatile uint32_t _ulTickCount = 0 ;
2828
29- uint32_t millis ( void )
29+ unsigned long millis ( void )
3030{
3131// todo: ensure no interrupts
3232 return _ulTickCount ;
@@ -36,7 +36,7 @@ uint32_t millis( void )
3636// Theory: repeatedly take readings of SysTick counter, millis counter and SysTick interrupt pending flag.
3737// When it appears that millis counter and pending is stable and SysTick hasn't rolled over, use these
3838// values to calculate micros. If there is a pending SysTick, add one to the millis counter in the calculation.
39- uint32_t micros ( void )
39+ unsigned long micros ( void )
4040{
4141 uint32_t ticks , ticks2 ;
4242 uint32_t pend , pend2 ;
@@ -61,7 +61,7 @@ uint32_t micros( void )
6161 // a runtime multiplication and shift, saving a few cycles
6262}
6363
64- void delay ( uint32_t ms )
64+ void delay ( unsigned long ms )
6565{
6666 if ( ms == 0 )
6767 {
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ extern "C" {
3333 *
3434 * \return Number of milliseconds since the program started (uint32_t)
3535 */
36- extern uint32_t millis ( void ) ;
36+ extern unsigned long millis ( void ) ;
3737
3838/**
3939 * \brief Returns the number of microseconds since the Arduino board began running the current program.
@@ -45,23 +45,23 @@ extern uint32_t millis( void ) ;
4545 *
4646 * \note There are 1,000 microseconds in a millisecond and 1,000,000 microseconds in a second.
4747 */
48- extern uint32_t micros ( void ) ;
48+ extern unsigned long micros ( void ) ;
4949
5050/**
5151 * \brief Pauses the program for the amount of time (in miliseconds) specified as parameter.
5252 * (There are 1000 milliseconds in a second.)
5353 *
5454 * \param dwMs the number of milliseconds to pause (uint32_t)
5555 */
56- extern void delay ( uint32_t dwMs ) ;
56+ extern void delay ( unsigned long dwMs ) ;
5757
5858/**
5959 * \brief Pauses the program for the amount of time (in microseconds) specified as parameter.
6060 *
6161 * \param dwUs the number of microseconds to pause (uint32_t)
6262 */
63- static __inline__ void delayMicroseconds ( uint32_t ) __attribute__((always_inline , unused )) ;
64- static __inline__ void delayMicroseconds ( uint32_t usec )
63+ static __inline__ void delayMicroseconds ( unsigned int ) __attribute__((always_inline , unused )) ;
64+ static __inline__ void delayMicroseconds ( unsigned int usec )
6565{
6666 if ( usec == 0 )
6767 {
You can’t perform that action at this time.
0 commit comments