• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

テスト用のあれこれ共用フォルダ


Commit MetaInfo

Revision5de0e6111074f4882c51225d5245a1956cbff670 (tree)
Time2018-02-27 07:15:45
Authortakemasa <suikan@user...>
Commitertakemasa

Log Message

Added basefifo

Change Summary

Incremental Difference

--- a/stm32_development/murasaki/NUCLEO-F746ZG.xml
+++ b/stm32_development/murasaki/NUCLEO-F746ZG.xml
@@ -12,8 +12,8 @@
1212 <targetDefinitions>
1313 <board id="nucleo-f746zg">
1414 <name>NUCLEO-F746ZG</name>
15- <dbgIF>JTAG</dbgIF>
1615 <dbgIF>SWD</dbgIF>
16+ <dbgIF>JTAG</dbgIF>
1717 <dbgDEV>ST-Link</dbgDEV>
1818 <mcuId>stm32f746zgtx</mcuId>
1919 </board>
--- /dev/null
+++ b/stm32_development/murasaki/murasaki/basefifo.cpp
@@ -0,0 +1,23 @@
1+/*
2+ * basefifo.cpp
3+ *
4+ * Created on: 2018/02/26
5+ * Author: takemasa
6+ */
7+
8+#include <basefifo.hpp>
9+
10+namespace murasaki {
11+
12+BaseFifo::BaseFifo()
13+{
14+ // TODO Auto-generated constructor stub
15+
16+}
17+
18+BaseFifo::~BaseFifo()
19+{
20+ // TODO Auto-generated destructor stub
21+}
22+
23+} /* namespace murasaki */
--- /dev/null
+++ b/stm32_development/murasaki/murasaki/basefifo.hpp
@@ -0,0 +1,32 @@
1+/*
2+ * basefifo.hpp
3+ *
4+ * Created on: 2018/02/26
5+ * Author: takemasa
6+ */
7+
8+#ifndef BASEFIFO_HPP_
9+#define BASEFIFO_HPP_
10+
11+#include <ctype.h>
12+
13+namespace murasaki {
14+
15+class BaseFifo
16+{
17+ public:
18+ BaseFifo(unsigned int buffer_size);
19+ virtual ~BaseFifo();
20+ unsigned int Put(uint8_t const data[], unsigned int size);
21+ unsigned int Get(uint8_t data[], unsigned int size);
22+ void ReWind();
23+ private:
24+ unsigned int head_ = 0;
25+ unsigned int tail_ = 0;
26+ uint8_t * const buffer_;
27+
28+};
29+
30+} /* namespace murasaki */
31+
32+#endif /* BASEFIFO_HPP_ */
--- /dev/null
+++ b/stm32_development/murasaki/murasaki/basefifo_test.cpp
@@ -0,0 +1,12 @@
1+/*
2+ * basefifo_test.cpp
3+ *
4+ * Created on: 2018/02/26
5+ * Author: takemasa
6+ */
7+
8+#include <basefifo.hpp>
9+
10+namespace murasaki {
11+
12+} /* namespace murasaki */