Skip to content
This repository has been archived by the owner on Aug 21, 2024. It is now read-only.

Commit

Permalink
move disable warnings to pragmas
Browse files Browse the repository at this point in the history
  • Loading branch information
zerog2k committed Aug 10, 2018
1 parent 28a2fb0 commit 5fca10c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
4 changes: 0 additions & 4 deletions post_extra_script.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@

# compiler and linker flags dont work very well in build_flags of platformio.ini - need to set them here
env.Append(
CFLAGS = [
"--disable-warning", 126,
"--disable-warning", 59
],
LINKFLAGS = [
"--data-loc", 0x30
],
Expand Down
2 changes: 2 additions & 0 deletions src/ds1302.c
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

#pragma callee_saves sendbyte,readbyte
#pragma callee_saves ds_writebyte,ds_readbyte
// silence: "src/ds1302.c:84: warning 59: function 'readbyte' must return value"
#pragma disable_warning 59

#include "ds1302.h"

Expand Down
5 changes: 4 additions & 1 deletion src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,16 @@
// Copyright 2016, Jens Jensen
//

// silence: "src/main.c:672: warning 126: unreachable code"
#pragma disable_warning 126

#include "stc15.h"
#include <stdint.h>
#include <stdio.h>
#include "adc.h"
#include "ds1302.h"
#include "led.h"

#define FOSC 11059200

// clear wdt
Expand Down

0 comments on commit 5fca10c

Please sign in to comment.