Skip to content

Commit

Permalink
1.0.10 lots of great things !
Browse files Browse the repository at this point in the history
  • Loading branch information
benkuper committed Jul 19, 2019
1 parent bc15d37 commit 87c7791
Show file tree
Hide file tree
Showing 37 changed files with 281 additions and 89 deletions.
2 changes: 1 addition & 1 deletion BenTo.jucer
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>

<JUCERPROJECT name="BenTo" projectType="guiapp" jucerVersion="5.4.3" headerPath="../../Source"
id="LP0of5" version="1.0.9">
id="LP0of5" version="1.0.10">
<MAINGROUP id="zy2ady" name="BenTo">
<GROUP id="{870E4241-9C31-E9AA-906B-7213EC4B54C1}" name="Resources">
<GROUP id="{9DFF626B-2FA9-675B-A3EB-1B7780D709F0}" name="models">
Expand Down
4 changes: 2 additions & 2 deletions Builds/LinuxMakefile/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ ifeq ($(CONFIG),Debug)
TARGET_ARCH := -m64
endif

JUCE_CPPFLAGS := $(DEPFLAGS) -DLINUX=1 -DDEBUG=1 -D_DEBUG=1 -DJUCER_LINUX_MAKE_6D53C8B4=1 -DJUCE_APP_VERSION=1.0.9 -DJUCE_APP_VERSION_HEX=0x10009 $(shell pkg-config --cflags alsa freetype2 x11 xext xinerama webkit2gtk-4.0 gtk+-x11-3.0 libcurl) -pthread -I../../JuceLibraryCode -I$(HOME)/JUCE/modules -I../../../JUCE\ Modules -I../../External/serial/include -I../../Source $(CPPFLAGS)
JUCE_CPPFLAGS := $(DEPFLAGS) -DLINUX=1 -DDEBUG=1 -D_DEBUG=1 -DJUCER_LINUX_MAKE_6D53C8B4=1 -DJUCE_APP_VERSION=1.0.10 -DJUCE_APP_VERSION_HEX=0x1000a $(shell pkg-config --cflags alsa freetype2 x11 xext xinerama webkit2gtk-4.0 gtk+-x11-3.0 libcurl) -pthread -I../../JuceLibraryCode -I$(HOME)/JUCE/modules -I../../../JUCE\ Modules -I../../External/serial/include -I../../Source $(CPPFLAGS)
JUCE_CPPFLAGS_APP := -DJucePlugin_Build_VST=0 -DJucePlugin_Build_VST3=0 -DJucePlugin_Build_AU=0 -DJucePlugin_Build_AUv3=0 -DJucePlugin_Build_RTAS=0 -DJucePlugin_Build_AAX=0 -DJucePlugin_Build_Standalone=0 -DJucePlugin_Build_Unity=0
JUCE_TARGET_APP := BenTo

Expand All @@ -56,7 +56,7 @@ ifeq ($(CONFIG),Release)
TARGET_ARCH := -m64
endif

JUCE_CPPFLAGS := $(DEPFLAGS) -DLINUX=1 -DNDEBUG=1 -DJUCER_LINUX_MAKE_6D53C8B4=1 -DJUCE_APP_VERSION=1.0.9 -DJUCE_APP_VERSION_HEX=0x10009 $(shell pkg-config --cflags alsa freetype2 x11 xext xinerama webkit2gtk-4.0 gtk+-x11-3.0 libcurl) -pthread -I../../JuceLibraryCode -I$(HOME)/JUCE/modules -I../../../JUCE\ Modules -I../../External/serial/include -I../../Source $(CPPFLAGS)
JUCE_CPPFLAGS := $(DEPFLAGS) -DLINUX=1 -DNDEBUG=1 -DJUCER_LINUX_MAKE_6D53C8B4=1 -DJUCE_APP_VERSION=1.0.10 -DJUCE_APP_VERSION_HEX=0x1000a $(shell pkg-config --cflags alsa freetype2 x11 xext xinerama webkit2gtk-4.0 gtk+-x11-3.0 libcurl) -pthread -I../../JuceLibraryCode -I$(HOME)/JUCE/modules -I../../../JUCE\ Modules -I../../External/serial/include -I../../Source $(CPPFLAGS)
JUCE_CPPFLAGS_APP := -DJucePlugin_Build_VST=0 -DJucePlugin_Build_VST3=0 -DJucePlugin_Build_AU=0 -DJucePlugin_Build_AUv3=0 -DJucePlugin_Build_RTAS=0 -DJucePlugin_Build_AAX=0 -DJucePlugin_Build_Standalone=0 -DJucePlugin_Build_Unity=0
JUCE_TARGET_APP := BenTo

Expand Down
8 changes: 4 additions & 4 deletions Builds/MacOSX/BenTo.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -3443,8 +3443,8 @@
"_DEBUG=1",
"DEBUG=1",
"JUCER_XCODE_MAC_F6D2F4CF=1",
"JUCE_APP_VERSION=1.0.9",
"JUCE_APP_VERSION_HEX=0x10009",
"JUCE_APP_VERSION=1.0.10",
"JUCE_APP_VERSION_HEX=0x1000a",
"JucePlugin_Build_VST=0",
"JucePlugin_Build_VST3=0",
"JucePlugin_Build_AU=0",
Expand Down Expand Up @@ -3488,8 +3488,8 @@
"_NDEBUG=1",
"NDEBUG=1",
"JUCER_XCODE_MAC_F6D2F4CF=1",
"JUCE_APP_VERSION=1.0.9",
"JUCE_APP_VERSION_HEX=0x10009",
"JUCE_APP_VERSION=1.0.10",
"JUCE_APP_VERSION_HEX=0x1000a",
"JucePlugin_Build_VST=0",
"JucePlugin_Build_VST3=0",
"JucePlugin_Build_AU=0",
Expand Down
4 changes: 2 additions & 2 deletions Builds/MacOSX/Info-App.plist
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleShortVersionString</key>
<string>1.0.9</string>
<string>1.0.10</string>
<key>CFBundleVersion</key>
<string>1.0.9</string>
<string>1.0.10</string>
<key>NSHumanReadableCopyright</key>
<string></string>
<key>NSHighResolutionCapable</key>
Expand Down
8 changes: 4 additions & 4 deletions Builds/MacOSX_CI/BenTo.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -3443,8 +3443,8 @@
"_DEBUG=1",
"DEBUG=1",
"JUCER_XCODE_MAC_2F3811D6=1",
"JUCE_APP_VERSION=1.0.9",
"JUCE_APP_VERSION_HEX=0x10009",
"JUCE_APP_VERSION=1.0.10",
"JUCE_APP_VERSION_HEX=0x1000a",
"JucePlugin_Build_VST=0",
"JucePlugin_Build_VST3=0",
"JucePlugin_Build_AU=0",
Expand Down Expand Up @@ -3488,8 +3488,8 @@
"_NDEBUG=1",
"NDEBUG=1",
"JUCER_XCODE_MAC_2F3811D6=1",
"JUCE_APP_VERSION=1.0.9",
"JUCE_APP_VERSION_HEX=0x10009",
"JUCE_APP_VERSION=1.0.10",
"JUCE_APP_VERSION_HEX=0x1000a",
"JucePlugin_Build_VST=0",
"JucePlugin_Build_VST3=0",
"JucePlugin_Build_AU=0",
Expand Down
4 changes: 2 additions & 2 deletions Builds/MacOSX_CI/Info-App.plist
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleShortVersionString</key>
<string>1.0.9</string>
<string>1.0.10</string>
<key>CFBundleVersion</key>
<string>1.0.9</string>
<string>1.0.10</string>
<key>NSHumanReadableCopyright</key>
<string></string>
<key>NSHighResolutionCapable</key>
Expand Down
2 changes: 1 addition & 1 deletion Builds/VS2017_CI/BenTo_App.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
<ClCompile>
<Optimization>Full</Optimization>
<AdditionalIncludeDirectories>..\..\JuceLibraryCode;..\..\..\JUCE\modules;..\..\..\JUCE Modules;../../External/asio;../../External/serial/include;../../Source;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32;_WINDOWS;NDEBUG;JUCER_VS2017_6069D29A=1;JUCE_APP_VERSION=1.0.9;JUCE_APP_VERSION_HEX=0x10009;JucePlugin_Build_VST=0;JucePlugin_Build_VST3=0;JucePlugin_Build_AU=0;JucePlugin_Build_AUv3=0;JucePlugin_Build_RTAS=0;JucePlugin_Build_AAX=0;JucePlugin_Build_Standalone=0;JucePlugin_Build_Unity=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32;_WINDOWS;NDEBUG;JUCER_VS2017_6069D29A=1;JUCE_APP_VERSION=1.0.10;JUCE_APP_VERSION_HEX=0x1000a;JucePlugin_Build_VST=0;JucePlugin_Build_VST3=0;JucePlugin_Build_AU=0;JucePlugin_Build_AUv3=0;JucePlugin_Build_RTAS=0;JucePlugin_Build_AAX=0;JucePlugin_Build_Standalone=0;JucePlugin_Build_Unity=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
<RuntimeTypeInfo>true</RuntimeTypeInfo>
<PrecompiledHeader/>
Expand Down
6 changes: 3 additions & 3 deletions Builds/VS2017_CI/resources.rc
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@
#include <windows.h>

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,0,9,0
FILEVERSION 1,0,10,0
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040904E4"
BEGIN
VALUE "FileDescription", "BenTo\0"
VALUE "FileVersion", "1.0.9\0"
VALUE "FileVersion", "1.0.10\0"
VALUE "ProductName", "BenTo\0"
VALUE "ProductVersion", "1.0.9\0"
VALUE "ProductVersion", "1.0.10\0"
END
END

Expand Down
52 changes: 31 additions & 21 deletions Firmware/BentoFlowCreator/BWebServer.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,39 +17,49 @@ class BentoWebServer
static int uploadedBytes;

static bool isUploading;

static int uploadIndex;

bool isEnabled;

BentoWebServer()
{
instance = this;

server.onNotFound(BentoWebServer::handleNotFound);
server.on("/upload", HTTP_POST, []() { returnOK(); }, BentoWebServer::handleFileUpload);
}

void init()
{
server.onNotFound(BentoWebServer::handleNotFound);
server.on("/upload", HTTP_POST, []() {
returnOK();
},
BentoWebServer::handleFileUpload
);

server.begin();
DBG("HTTP server started");

/* if (MDNS.begin(settings.deviceID.c_str())) {
MDNS.addService("http", "tcp", 80);
DBG("MDNS responder started, you can now connect to http://"+settings.deviceID+".local");
}
*/

isUploading = false;
isEnabled = false;

addUploadStartCallback(&BentoWebServer::onUploadDefaultCallback);
addUploadProgressCallback(&BentoWebServer::onUploadProgressDefaultCallback);
addUploadFinishCallback(&BentoWebServer::onUploadDefaultCallback);

isUploading = false;
initServer();

}

void initServer()
{
server.begin();
DBG("HTTP server started");
isEnabled = true;
}

void closeServer()
{
server.close();
DBG("HTTP server closed");
isEnabled = false;
}

void update()
{
if(!isEnabled) return;

server.handleClient();
}

Expand All @@ -65,6 +75,7 @@ class BentoWebServer
{
uploadedBytes = 0;
//totalBytes = server.header("Content-Length").toInt();
uploadIndex = 0;

uploadingFile = FileManager::openFile(upload.filename, true, true);
if(uploadingFile)
Expand All @@ -91,10 +102,9 @@ class BentoWebServer
}

uploadedBytes += upload.currentSize;

DBG("Uploaded "+String(uploadedBytes));
float p = uploadedBytes*1.0f/1000000;
if(uploadedBytes % 4000 < 2000) instance->onUploadProgressEvent(p);
if(uploadedBytes % 8000 < 4000) instance->onUploadProgressEvent(p);
}
}
else if (upload.status == UPLOAD_FILE_END)
Expand Down Expand Up @@ -157,5 +167,5 @@ WebServer BentoWebServer::server(80);
File BentoWebServer::uploadingFile;
int BentoWebServer::uploadedBytes = 0;
bool BentoWebServer::isUploading = false;
//static BentoWebServer::totalBytes = 1000000;
int BentoWebServer::uploadIndex = 0;
#endif
9 changes: 7 additions & 2 deletions Firmware/BentoFlowCreator/BakePlayer.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ class BakePlayer
float timeToSeek; //used to limit seeking

bool idMode;
bool loopShow = false;

BakePlayer()
{
Expand Down Expand Up @@ -71,8 +72,12 @@ class BakePlayer
{
if(curFile.available() < FRAME_SIZE)
{
DBG("End of show, available = "+String(curFile.available()));
play(0);
DBG("End of show");
if(loopShow)
{
DBG("Loop");
play(0);
}
}

long mil = millis();
Expand Down
Loading

0 comments on commit 87c7791

Please sign in to comment.