Welcome to TiddlyWiki created by Jeremy Ruston, Copyright © 2007 UnaMesa Association
In Socialtext Unplugged, the selected pages of your Socialtext workspace are displayed as individual "tiddlers" on the page. When the mouse passes over a tiddler a short toolbar menu appears at the top right. Use the commands here to manipulate that particular tiddler: notably closing and editting it. (You can double click on a tiddler as a shortcut to directly enter edit mode).
Over on the right hand side of the window are commands that affect the entire page, in particular "close all" which can be useful to clear the decks when many tiddlers are open at once.
The user is encouraged to ensure that they can SaveChanges before embarking on widespread editing.
Welcome to Socialtext Unplugged. This is a specially designed web page that you can use to view and edit your Socialtext content without having to be online to your Socialtext server.
There are three steps to using Socialtext Unplugged:
* First, learn how to SaveChanges to your local hard drive. This keeps your work safe even if you close your browser or have to reboot your computer
* Secondly, find out how to BrowseAndEdit your content while it is unplugged
* Thirdly, when you can reconnect to your Socialtext server, you can SyncChanges to save your unplugged changes to the server so that other people can see them too
You should also check your system meets the SystemRequirements.
<!--{{{-->
<div class='header' macro='gradient vert [[ColorPalette::PrimaryLight]] [[ColorPalette::PrimaryMid]]'>
<div class='headerShadow'>
<span class='siteTitle' refresh='content' tiddler='SiteTitle'></span>
<span class='siteSubtitle' refresh='content' tiddler='SiteSubtitle'></span>
</div>
<div class='headerForeground'>
<span class='siteTitle' refresh='content' tiddler='SiteTitle'></span>
<span class='siteSubtitle' refresh='content' tiddler='SiteSubtitle'></span>
</div>
</div>
<div id='mainMenu' refresh='content' tiddler='MainMenu'></div>
<div id='sidebar'>
<div id='sidebarOptions' refresh='content' tiddler='SideBarOptions'></div>
<div id='sidebarTabs' refresh='content' force='true' tiddler='SideBarTabs'></div>
</div>
<div id='displayArea'>
<div id='messageArea'></div>
<div id='tiddlerDisplay'></div>
<div class="socialtextLogo"><img src="http://www.eu.socialtext.net/static/2.3.0.0/images/st/logo/socialtext-logo-152x26.gif" width=152 height=26></div>
</div>
<!--}}}-->
Socialtext Unplugged lets you browse and edit your content while you're offline. When you make a change you need to SaveChanges to save the change to your local hard drive, before later performing a SyncChanges to synchronise the change back to the server.
The procedure for SaveChanges is slightly different for different browsers:
* SavingOnInternetExplorer
* SavingOnFireFox
* SavingOnSafari
* SavingOnOpera
You can save changes with any version of FireFox, and also many other browsers in the FireFox family, such as Camino on the Mac and MiniMo on mobile devices. The procedure is:
# Click the button labelled 'save changes' over in the right hand sidebar
# If prompted with an "Internet Security" dialog as follows, click the checkbox labelled "Remember this decision" and then the "Allow" button
## "A script from "file://" is requesting enhanced capabilities that are UNSAFE and could be used to compromise your machine or data..."
# You should then see a message at the top right of the window saying "Main TiddlyWiki file saved"
If you accidentally //deny// permission instead, you may need to UnravelFireFoxPermissions.
You can save changes with Internet Explorer versions 6 and 7, but not the earlier versions. The procedure is:
# Click the button labelled 'save changes' over in the right hand sidebar
# If prompted as follows, click "Yes":
## "An ActiveX control on this page might be unsafe to interact with other parts of the page. Do you want to allow this interaction?"
# You should then see a message at the top right of the window saying "Main TiddlyWiki file saved"
Note that there is currently [[a bug|http://trac.tiddlywiki.org/tiddlywiki/ticket/39]] that prevents Internet Explorer from saving correctly if you have specified a backup directory in AdvancedOptions.
To SaveChanges on Opera, see the instructions for using the TiddlySaver Java applet.
To SaveChanges on Safari, see the instructions for using the TiddlySaver Java applet.
<<search>><<closeAll>><<permaview>><<newTiddler 'New Tiddler' fields:'server.host:"https://saturn.ffzg.hr%2C%20saturn.ffzg.hr:443" server.workspace:"rot13" wikiformat:socialtext'>><<newJournal 'DD MMM YYYY' fields:'server.host:"https://saturn.ffzg.hr%2C%20saturn.ffzg.hr:443" server.workspace:"rot13" wikiformat:socialtext'>><<saveChanges>><<backstage sync>><<slider chkSliderOptionsPanel OptionsPanel 'options »' 'Change TiddlyWiki advanced options'>>
Dobrica Pavlinušić's random unstructured stuff
https://saturn.ffzg.hr/rot13/
[[SocialtextScreenStyle]]
[[SocialtextStyleOverrides]]
[[Styles HorizontalMainMenu]]
@@The user interface for synchronization is not finalized@@
To synchronize your changes back to the Socialtext server:
# click on [[Sync]] in the right-hand sidebar
<<tabs txtMoreTab Orphans 'Orphaned tiddlers' TabMoreOrphans Shadowed 'Shadowed tiddlers' TabMoreShadowed>>
Under FireFox, you can run into problems if you accidentally click 'Deny' on the permission request dialog, and have selected //Remember this decision//.
To reverse the effects, first locate the file {{{prefs.js}}} in your FireFox profile directory. Under Windows you'll find it at something like {{{C:\Documents and Settings\Jeremy\Application Data\Mozilla\Firefox\Profiles\o3dhupu6.default\prefs.js}}}, where {{{Jeremy}}} is the name of your windows profile and {{{o3dhupu6}}} will be a similar string of gobbledegook. On the Mac it'll be at {{{~/Library/Application Support/Firefox/Profiles/o3dhupu6.default/prefs.js}}} and on most versions of Linux, at {{{~/.mozilla/firefox/o3dhupu6.default/prefs.js}}}.
Open the file in a text editor and find the line {{{user_pref("capability.principal.codebase.p0.denied", "UniversalXPConnect");}}} and simply replace the word {{{denied}}} with {{{granted}}}.
//(Thanks to JonScully for figuring out this fix)//
<!--{{{-->
<div class='toolbar' macro='toolbar closeTiddler closeOthers +editTiddler references > fields syncing jump'></div>
<div class='workspace' id='st-page-wiki-title' macro='view socialtext.workspace'></div>
<div class='title' id='st-page-titletext' macro='view title'></div>
<div class='subtitle'>
Created on <span macro='view created date [[MMM DD, 0hh:0mm]]'></span>.
Updated by <span macro='view modifier link'></span>
on <span macro='view modified date [[MMM DD, 0hh:0mm]]'></span></div>
<div class='tagging' macro='tagging'></div>
<div class='tagged' macro='tags'></span></div>
<div class='viewer' macro='view text wikified'></div>
<div class='tagClear'></div>
<!--}}}-->
/***
To use, add {{{[[Styles HorizontalMainMenu]]}}} to your StyleSheet tiddler.
See http://www.w3schools.com/css/css_colors.asp for a color chart.
***/
/*{{{*/
#mainMenu {position:relative;left:auto;width:auto;text-align:left;line-height:normal;padding 0em 1em 0em 1em;font-size:normal;}
#mainMenu br {display:none;}
#mainMenu {background:#336699;}
#mainMenu {padding:2px;}
#mainMenu .button, #mainMenu .tiddlyLink {padding-left:0.5em;padding-right:0.5em;color:white;font-size:115%;}
#displayArea {
margin-top:0;margin-right:20em;margin-bottom:0;margin-left:1em;
padding-top:.1em;padding-bottom:.1em;
}
/*}}}*/
|''Type:''|socialtext|
|''URL:''|https://saturn.ffzg.hr%2C%20saturn.ffzg.hr:443 |
|''Workspace:''|rot13|
|''WorkspaceList:''||
|''Description:''|Dobrica Pavlinušić's random unstructured stuff|
The TiddlySaver Java applet allows TiddlyWiki from a {{{file://}}} URL to save changes Safari, Opera and other browsers.
It is a small file named [["TiddlySaver.jar"|TiddlySaver.jar]] that must be placed in the same directory as your TiddlyWiki file. Before you can use it, you need to give it the necessary privileges by editting your {{{.java.policy}}} file.
For Windows, the file will be at {{{C:\Documents and Settings\your-user-name\.java.policy}}}. Add the following lines (substituting the directory of your TiddlyWiki file as appropriate):
{{{
grant codeBase "file:${user.home}/My Documents/tiddlywiki-folder/*" {
permission java.io.FilePermission "${user.home}${/}My Documents${/}tiddlywiki-folder${/}*", "read,write";
};
}}}
On Mac OS X, the file is found at {{{/Users/your-user-name/.java.policy}}}:
{{{
grant codeBase "file:${user.home}/Documents/tiddlywiki-folder/*" {
permission java.io.FilePermission "${user.home}${/}Documents${/}tiddlywiki-folder${/}*", "read,write";
};
}}}
It can be tricky creating files whose name starts with a period, so you can use this [[pre-built .java.policy file|.java.policy]]. The same file is suitable for Macs too, just edit it and delete the "My " bit, leaving just "Documents". Make sure you save it in the right place for each operating system!
If you have trouble setting up the permissions correctly, you can try granting broader permissions to the applet like this:
{{{
grant codeBase "file://localhost/home/users/Desktop/
TiddlySaver.jar"
{ permission java.security.AllPermission; };
}}}
Note that there is currently [[a bug|http://trac.tiddlywiki.org/ticket/172]] that prevents TiddlySaver from working if you have specified a backup directory in AdvancedOptions.
/***
|''Name:''|SocialtextLocaleOverrides|
|''Description:''|Text changes for Socialtext|
***/
//{{{
merge(config.views.wikified.tag,{
labelNoTags: "No Tags",
labelTags: "Tags"});
merge(config.commands.references,{
text: "incoming links",
tooltip: "Show tiddlers that link to this one",
popupNone: "No incoming links"});
//}}}
/***
|''Name:''|SocialtextTweaksPlugin|
|''Description:''|Allows changes to be synchronised with a Socialtext server|
|''Source:''|http://stunplugged.tiddlywiki.com/#SocialtextTweaksPlugin|
|''Author:''|JeremyRuston (jeremy (at) osmosoft (dot) com)|
|''Version:''|1.0.2|
|''Date:''|Jun 15, 2006|
|''Comments:''|Please make comments at http://groups.google.co.uk/group/TiddlyWikiDev|
|''License:''|[[BSD open source license]]|
|''~CoreVersion:''|2.2|
Make minor configuration tweaks specific to Socialtext Unplugged
***/
//{{{
// Ensure that the SocialtextTweaksPlugin is only installed once.
if(!version.extensions.SocialtextTweaksPlugin) {
version.extensions.SocialtextTweaksPlugin = {installed:true};
// Check version number of core code
if(version.major < 2 || (version.major == 2 && version.minor < 2))
{alertAndThrow("SocialtextTweaksPlugin requires TiddlyWiki 2.2 or later.");}
merge(config.defaultCustomFields,{
wikiformat:'socialtext',
'server.host':'https://saturn.ffzg.hr%2C%20saturn.ffzg.hr:443'
});
config.options.chkSinglePageMode = true;
config.options.chkEnableAnimations = true;
} // end of "install only once"
//}}}
/***
|''Name:''|SocialtextFormatterPlugin|
|''Description:''|Allows Tiddlers to use [[Socialtext|http://www.socialtext.com/]] text formatting|
|''Author:''|Martin Budden (mjbudden (at) gmail (dot) com)|
|''Source:''|http://www.martinswiki.com/#SocialtextFormatterPlugin|
|''CodeRepository:''|http://svn.tiddlywiki.org/Trunk/contributors/MartinBudden/formatters/SocialtextFormatterPlugin.js|
|''Version:''|0.9.4|
|''Date:''|Jan 21, 2007|
|''Comments:''|Please make comments at http://groups.google.co.uk/group/TiddlyWikiDev|
|''License:''|[[Creative Commons Attribution-ShareAlike 2.5 License|http://creativecommons.org/licenses/by-sa/2.5/]]|
|''~CoreVersion:''|2.1.0|
This is the SocialtextFormatterPlugin, which allows you to insert Socialtext formated text into a TiddlyWiki.
The aim is not to fully emulate Socialtext, but to allow you to work with Socialtext content off-line and then resync the content with your Socialtext wiki later on, with the expectation that only minor edits will be required.
To use Socialtext format in a Tiddler, tag the Tiddler with SocialtextFormat or set the tiddler's {{{wikiformat}}} extended field to {{{socialtext}}}
Please report any defects you find at http://groups.google.co.uk/group/TiddlyWikiDev
***/
//{{{
// Ensure that the SocialtextFormatter Plugin is only installed once.
if(!version.extensions.SocialtextFormatterPlugin) {
version.extensions.SocialtextFormatterPlugin = {installed:true};
if(version.major < 2 || (version.major == 2 && version.minor < 1))
{alertAndThrow('SocialtextFormatterPlugin requires TiddlyWiki 2.1 or later.');}
SocialtextFormatter = {}; // 'namespace' for local functions
wikify = function(source,output,highlightRegExp,tiddler)
{
if(source && source != '') {
var w = new Wikifier(source,getParser(tiddler),highlightRegExp,tiddler);
var out = output;
if(tiddler && (tiddler.isTagged(config.parsers.socialtextFormatter.formatTag) || (tiddler.fields.wikiformat==config.parsers.socialtextFormatter.format)) ) {
var d1 = createTiddlyElement(output,'div','content-display-body','content-section-visible');
var d2 = createTiddlyElement(d1,'div','wikipage');
out = createTiddlyElement(d2,'div',null,'wiki');
}
var time1,time0 = new Date();
w.subWikifyUnterm(out);
if(tiddler && config.options.chkDisplayInstrumentation) {
time1 = new Date();
var t = tiddler ? tiddler.title : source.substr(0,10);
displayMessage("Wikify '"+t+"' in " + (time1-time0) + " ms");
}
}
};
stDebug = function(out,str)
{
createTiddlyText(out,str.replace(/\n/mg,'\\n').replace(/\r/mg,'RR'));
createTiddlyElement(out,'br');
};
SocialtextFormatter.Tiddler_changed = Tiddler.prototype.changed;
Tiddler.prototype.changed = function()
{
if((this.fields.wikiformat==config.parsers.socialtextFormatter.format) || this.isTagged(config.parsers.socialtextFormatter.formatTag)) {
// update the links array, by checking for Socialtext format links
this.links = [];
var tiddlerLinkRegExp = /(?:\"(.*?)\" ?)?\[([^\]]*?)\]/mg;
tiddlerLinkRegExp.lastIndex = 0;
var match = tiddlerLinkRegExp.exec(this.text);
while(match) {
var link = match[2];
this.links.pushUnique(link);
match = tiddlerLinkRegExp.exec(this.text);
}
}/* else {
return SocialtextFormatter.Tiddler_changed.apply(this,arguments);
}*/
this.linksUpdated = true;
};
SocialtextFormatter.wafl = function(w)
{
this.lookaheadRegExp.lastIndex = w.matchStart;
var lookaheadMatch = this.lookaheadRegExp.exec(w.source);
if(lookaheadMatch && lookaheadMatch.index == w.matchStart) {
var lm2 = lookaheadMatch[2];
switch(lookaheadMatch[1]) {
case 'image':
var img = createTiddlyElement(w.output,'img');
img.src = w.tiddler.title + '/' + lm2;
createTiddlyText(img,lm2);
break;
case 'file':
var s = createTiddlyElement(w.output,'span',null,'nlw_phrase');
var a = createTiddlyElement(s,'a');
a.href = w.tiddler.title + '/' + lm2;
createTiddlyText(a,lm2);
break;
case 'link':
s = createTiddlyElement(w.output,'span',null,'nlw_phrase');
a = createTiddlyElement(s,'a');
var t = w.tiddler ? w.tiddler.title + ':' : '';
a.setAttribute('href','#' + t + lm2);
a.title = 'section link';
createTiddlyText(a,lm2);
break;
case 'weblog':
s = createTiddlyElement(w.output,'span',null,'nlw_phrase');
var text = lm2;
var link = 'Weblog: ' + lm2;
createTiddlyText(createTiddlyLink(s,link,false,null,w.isStatic),text);
break;
case 'section':
a = createTiddlyElement(w.output,'a');// drop anchor
t = w.tiddler ? w.tiddler.title + ':' : '';
a.setAttribute('name',t + lm2);
break;
case 'date':
createTiddlyText(w.output,lm2);
break;
case 'user':
var oldSource = w.source;
w.source = lm2;
w.nextMatch = 0;
w.subWikifyUnterm(w.output);
w.source = oldSource;
break;
// Shortcut expansions - not strictly syntax
case 'google':
s = createTiddlyElement(w.output,'span',null,'nlw_phrase');
a = createExternalLink(s,'http://www.google.com/search?q='+lm2);
createTiddlyText(a,lm2);
break;
case 'fedex':
s = createTiddlyElement(w.output,'span',null,'nlw_phrase');
a = createExternalLink(s,'http://www.fedex.com/Tracking?tracknumbers='+lm2);
createTiddlyText(a,lm2);
break;
case 'map':
s = createTiddlyElement(w.output,'span',null,'nlw_phrase');
a = createExternalLink(s,'http://maps.google.com/maps?q='+lm2);
createTiddlyText(a,lm2);
break;
case 'wikipedia':
s = createTiddlyElement(w.output,'span',null,'nlw_phrase');
a = createExternalLink(s,'http://en.wikipedia.org/wiki/'+lm2);
createTiddlyText(a,lm2);
break;
case 'rt':
s = createTiddlyElement(w.output,'span',null,'nlw_phrase');
a = createExternalLink(s,'http://rt.socialtext.net/Ticket/Display.html?id='+lm2);
createTiddlyText(a,lm2);
break;
case 'stcal':
s = createTiddlyElement(w.output,'span',null,'nlw_phrase');
a = createExternalLink(s,'https://calendar.socialtext.net:445/view_t.php?timeb=1&id=3&date='+lm2);
createTiddlyText(a,lm2);
break;
case 'svn':
s = createTiddlyElement(w.output,'span',null,'nlw_phrase');
a = createExternalLink(s,'https://repo.socialtext.net/listing.php?rev='+lm2+'sc=1');
createTiddlyText(a,lm2);
break;
default:
w.outputText(w.output,w.matchStart,w.nextMatch);
return;
}
w.nextMatch = this.lookaheadRegExp.lastIndex;
} else {
w.outputText(w.output,w.matchStart,w.nextMatch);
}
};
SocialtextFormatter.presence = function(w)
{
this.lookaheadRegExp.lastIndex = w.matchStart;
var lookaheadMatch = this.lookaheadRegExp.exec(w.source);
if(lookaheadMatch && lookaheadMatch.index == w.matchStart) {
var p = lookaheadMatch[1];
var text = lookaheadMatch[2];
var link;
var src;
if(p=='aim') {
link = 'aim:goim?screenname=' + text + '&message=hello';
src = 'http://big.oscar.aol.com/sleepleft?on_url=http://www.aim.com/remote/gr/MNB_online.gif&off_url=http://www.aim.com/remote/gr/MNB_offline.gif';
} else if(p=='yahoo'||p=='ymsgr') {
link = 'ymsgr:sendIM?'+text;
src = 'http://opi.yahoo.com/online?u=chrislondonbridge&f=.gif';
} else if(p=='skype'||p=='callto') {
link = 'callto:'+text;
src = 'http://goodies.skype.com/graphics/skypeme_btn_small_green.gif';
} else if(p=='asap') {
link = 'http://asap2.convoq.com/AsapLinks/Meet.aspx?l='+text;
src = 'http://asap2.convoq.com/AsapLinks/Presence.aspx?l='+text;
}
var s = createTiddlyElement(w.output,'span',null,'nlw_phrase');
var a = createExternalLink(s,link);
var img = createTiddlyElement(a,'img');
createTiddlyText(a,text);
img.src = src;
img.border='0';
img.alt = '(' + lookaheadMatch[1] + ')';
if(p=='aim') {
img.width='11'; img.height='13';
}
w.nextMatch = this.lookaheadRegExp.lastIndex;
}
};
config.formatterHelpers.singleCharFormat = function(w)
{
this.lookaheadRegExp.lastIndex = w.matchStart;
var lookaheadMatch = this.lookaheadRegExp.exec(w.source);
if(lookaheadMatch && lookaheadMatch.index == w.matchStart && lookaheadMatch[0].substr(lookaheadMatch[0].length-2,1) != ' ') {
w.subWikifyTerm(createTiddlyElement(w.output,this.element),this.termRegExp);
} else {
w.outputText(w.output,w.matchStart,w.nextMatch);
}
};
config.socialtext = {};
config.socialtext.formatters = [
{
name: 'socialtextHeading',
match: '^\\^{1,6} ?',
termRegExp: /(\n+)/mg,
handler: function(w)
{
var len = w.matchText.trim().length;
var e = createTiddlyElement(w.output,'h' + len);
var a = createTiddlyElement(e,'a');// drop anchor
var t = w.tiddler ? w.tiddler.title + ':' : '';
len = w.source.substr(w.nextMatch).indexOf('\n');
a.setAttribute('name',t+w.source.substr(w.nextMatch,len));
w.subWikifyTerm(e,this.termRegExp);
}
},
{
name: 'socialtextTable',
match: '^\\|(?:(?:.|\n)*)\\|$',
lookaheadRegExp: /^\|(?:(?:.|\n)*)\|$/mg,
cellRegExp: /(?:\|(?:[^\|]*)\|)(\n|$)?/mg,
cellTermRegExp: /((?:\x20*)\|)/mg,
handler: function(w)
{
var table = createTiddlyElement(w.output,'table');
var rowContainer = createTiddlyElement(table,'tbody');
var prevColumns = [];
w.nextMatch = w.matchStart;
this.lookaheadRegExp.lastIndex = w.nextMatch;
var lookaheadMatch = this.lookaheadRegExp.exec(w.source);
while(lookaheadMatch && lookaheadMatch.index == w.nextMatch) {
var r = this.rowHandler(w,createTiddlyElement(rowContainer,'tr'),prevColumns);
if(!r) {
w.nextMatch++;
break;
}
this.lookaheadRegExp.lastIndex = w.nextMatch;
lookaheadMatch = this.lookaheadRegExp.exec(w.source);
}
},
rowHandler: function(w,e,prevColumns)
{
this.cellRegExp.lastIndex = w.nextMatch;
var cellMatch = this.cellRegExp.exec(w.source);
while(cellMatch && cellMatch.index == w.nextMatch) {
w.nextMatch++;
var cell = createTiddlyElement(e,'td');
w.subWikifyTerm(cell,this.cellTermRegExp);
if(cellMatch[1]) {
// End of row
w.nextMatch = this.cellRegExp.lastIndex;
return true;
}
// Cell
w.nextMatch--;
this.cellRegExp.lastIndex = w.nextMatch;
cellMatch = this.cellRegExp.exec(w.source);
}
return false;
}
},
{
name: 'socialtextList',
match: '^[\\*#]+ ',
lookaheadRegExp: /^([\*#])+ /mg,
termRegExp: /(\n+)/mg,
handler: function(w)
{
var stack = [w.output];
var currLevel = 0, currType = null;
var itemType = 'li';
w.nextMatch = w.matchStart;
this.lookaheadRegExp.lastIndex = w.nextMatch;
var lookaheadMatch = this.lookaheadRegExp.exec(w.source);
while(lookaheadMatch && lookaheadMatch.index == w.nextMatch) {
var listType = lookaheadMatch[1] == '*' ? 'ul' : 'ol';
var listLevel = lookaheadMatch[0].length;
w.nextMatch += listLevel;
if(listLevel > currLevel) {
for(var i=currLevel; i<listLevel; i++) {
stack.push(createTiddlyElement(stack[stack.length-1],listType));
}
} else if(listLevel < currLevel) {
for(i=currLevel; i>listLevel; i--) {
stack.pop();
}
} else if(listLevel == currLevel && listType != currType) {
stack.pop();
stack.push(createTiddlyElement(stack[stack.length-1],listType));
}
currLevel = listLevel;
currType = listType;
var e = createTiddlyElement(stack[stack.length-1],itemType);
w.subWikifyTerm(e,this.termRegExp);
this.lookaheadRegExp.lastIndex = w.nextMatch;
lookaheadMatch = this.lookaheadRegExp.exec(w.source);
}
}
},
{
name: 'socialtextQuoteByLine',
match: '^>+',
lookaheadRegExp: /^>+/mg,
termRegExp: /(\n)/mg,
element: 'blockquote',
handler: function(w)
{
var stack = [w.output];
var currLevel = 0;
var newLevel = w.matchLength;
var i;
do {
if(newLevel > currLevel) {
for(i=currLevel; i<newLevel; i++) {
stack.push(createTiddlyElement(stack[stack.length-1],this.element));
}
} else if(newLevel < currLevel) {
for(i=currLevel; i>newLevel; i--) {
stack.pop();
}
}
currLevel = newLevel;
w.subWikifyTerm(stack[stack.length-1],this.termRegExp);
createTiddlyElement(stack[stack.length-1],'br');
this.lookaheadRegExp.lastIndex = w.nextMatch;
var lookaheadMatch = this.lookaheadRegExp.exec(w.source);
var matched = lookaheadMatch && lookaheadMatch.index == w.nextMatch;
if(matched) {
newLevel = lookaheadMatch[0].length;
w.nextMatch += newLevel;
}
} while(matched);
}
},
{
name: 'socialtextRule',
match: '^----+$\\n+',
handler: function(w)
{
createTiddlyElement(w.output,'hr');
}
},
{
name: 'socialtextPreformatted',
match: '^\\.pre\\s*\\n',
lookaheadRegExp: /^.pre\s*\n((?:.|\n)*?)\n.pre\s*\n/mg,
element: 'pre',
handler: config.formatterHelpers.enclosedTextHelper
},
{
name: 'socialtextHtml',
match: '^\\.html',
lookaheadRegExp: /\.html((?:.|\n)*?)\.html/mg,
handler: function(w)
{
this.lookaheadRegExp.lastIndex = w.matchStart;
var lookaheadMatch = this.lookaheadRegExp.exec(w.source);
if(lookaheadMatch && lookaheadMatch.index == w.matchStart) {
createTiddlyElement(w.output,'span').innerHTML = lookaheadMatch[1];
w.nextMatch = this.lookaheadRegExp.lastIndex;
}
}
},
{
name: 'macro',
match: '<<',
lookaheadRegExp: /<<([^>\s]+)(?:\s*)((?:[^>]|(?:>(?!>)))*)>>/mg,
handler: function(w)
{
this.lookaheadRegExp.lastIndex = w.matchStart;
var lookaheadMatch = this.lookaheadRegExp.exec(w.source);
if(lookaheadMatch && lookaheadMatch.index == w.matchStart && lookaheadMatch[1]) {
w.nextMatch = this.lookaheadRegExp.lastIndex;
invokeMacro(w.output,lookaheadMatch[1],lookaheadMatch[2],w,w.tiddler);
}
}
},
{
name: 'socialtextExplicitLink',
match: '(?:".*?" ?)?\\[',
lookaheadRegExp: /(?:\"(.*?)\" ?)?\[([^\]]*?)\]/mg,
handler: function(w)
{
this.lookaheadRegExp.lastIndex = w.matchStart;
var lookaheadMatch = this.lookaheadRegExp.exec(w.source);
if(lookaheadMatch && lookaheadMatch.index == w.matchStart) {
var link = lookaheadMatch[2];
var text = lookaheadMatch[1] ? lookaheadMatch[1] : link;
createTiddlyText(createTiddlyLink(w.output,link,false,null,w.isStatic,w.tiddler),text);
w.nextMatch = this.lookaheadRegExp.lastIndex;
}
}
},
{
name: 'socialtextExternalLink',
match: '(?:".*?" ?)?<[a-z]{2,8}:',
lookaheadRegExp: /(?:\"(.*?)\" ?)?<([a-z]{2,8}:.*?)>/mg,
imgRegExp: /\.(?:gif|ico|jpg|png)/g,
handler: function(w)
{
this.lookaheadRegExp.lastIndex = w.matchStart;
var lookaheadMatch = this.lookaheadRegExp.exec(w.source);
if(lookaheadMatch && lookaheadMatch.index == w.matchStart) {
var link = lookaheadMatch[2];
var text = lookaheadMatch[1] ? lookaheadMatch[1] : link;
this.imgRegExp.lastIndex = 0;
if(this.imgRegExp.exec(link)) {
var img = createTiddlyElement(w.output,'img');
if(lookaheadMatch[1]) {
img.title = text;
}
img.alt = text;
img.src = link;
} else {
createTiddlyText(createExternalLink(w.output,link),text);
}
w.nextMatch = this.lookaheadRegExp.lastIndex;
}
}
},
{
name: 'socialtextUrlLink',
match: config.textPrimitives.urlPattern,
handler: function(w)
{
w.outputText(createExternalLink(w.output,w.matchText),w.matchStart,w.nextMatch);
}
},
{
name: 'socialtextBold',
match: '\\*(?![\\s\\*])',
lookaheadRegExp: /\*(?!\s)(?:.*?)(?!\s)\*(?=[$\s\|\._\-,])/mg,
termRegExp: /((?!\s)\*(?=[$\s\|\.\-_,]))/mg,
element: 'strong',
handler: config.formatterHelpers.singleCharFormat
},
{
name: 'socialtextItalic',
match: '_(?![\\s_])',
lookaheadRegExp: /_(?!\s)(?:.*?)(?!\s)_(?=[$\s\|\.\*\-,])/mg,
termRegExp: /((?!\s)_(?=[$\s\|\.\*\-,]))/mg,
element: 'em',
handler: config.formatterHelpers.singleCharFormat
},
{
name: 'socialtextStrike',
match: '-(?![\\s\\-])',
lookaheadRegExp: /-(?!\s)(?:.*?)(?!\s)-(?=[$\s\|\.\*_,])/mg,
termRegExp: /((?!\s)-(?=[$\s\|\.\*_,]))/mg,
element: 'del',
handler: config.formatterHelpers.singleCharFormat
},
{
name: 'socialtextMonoSpaced',
match: '`(?![\\s`])',
lookaheadRegExp: /`(?!\s)(?:.*?)(?!\s)`(?=[$\s\.\*\-_,])/mg,
termRegExp: /((?!\s)`(?=[$\s\.\*\-_,]))/mg,
element: 'tt',
handler: config.formatterHelpers.singleCharFormat
},
{
name: 'socialtextParagraph',
match: '\\n{2,}',
handler: function(w)
{
createTiddlyElement(w.output,'p');
}
},
{
name: 'socialtextLineBreak',
match: '\\n',
handler: function(w)
{
createTiddlyElement(w.output,'br');
}
},
{
name: 'socialtextNoWiki',
match: '\\{\\{',
lookaheadRegExp: /\{\{((?:.|\n)*?)\}\}/mg,
element: 'span',
handler: config.formatterHelpers.enclosedTextHelper
},
{
name: 'socialtextTrademark',
match: '\\{tm\\}',
handler: function(w)
{
createTiddlyElement(w.output,'span').innerHTML = '™';
}
},
{
name: 'socialtextWafl',
match: '\\{(?:[a-z]{2,16}): ?.*?\\}',
lookaheadRegExp: /\{([a-z]{2,16}): ?(.*?)\}/mg,
handler: SocialtextFormatter.wafl
},
{
name: 'socialtextPresence',
match: '(?:aim|yahoo|ymsgr|skype|callto|asap):\\w+',
lookaheadRegExp: /(aim|yahoo|ymsgr|skype|callto|asap):(\w+)/mg,
handler: SocialtextFormatter.presence
},
{
name: 'socialtextMailTo',
match: '[\\w\.]+@[\\w]+\.[\\w\.]+',
lookaheadRegExp: /([\w\.]+@[\w]+\.[\w\.]+)/mg,
handler: function(w)
{
this.lookaheadRegExp.lastIndex = w.matchStart;
var lookaheadMatch = this.lookaheadRegExp.exec(w.source);
if(lookaheadMatch && lookaheadMatch.index == w.matchStart) {
var text = lookaheadMatch[1];
createTiddlyText(createExternalLink(w.output,'mailto:'+text),text);
w.nextMatch = this.lookaheadRegExp.lastIndex;
}
}
},
{
name: 'socialtextHtmlEntitiesEncoding',
match: '&#?[a-zA-Z0-9]{2,8};',
handler: function(w)
{
createTiddlyElement(w.output,'span').innerHTML = w.matchText;
}
}
];
config.parsers.socialtextFormatter = new Formatter(config.socialtext.formatters);
config.parsers.socialtextFormatter.format = 'socialtext';
config.parsers.socialtextFormatter.formatTag = 'SocialtextFormat';
} // end of 'install only once'
//}}}
/***
|''Name:''|SocialtextAdaptorPlugin|
|''Description:''|Adaptor for moving and converting data to and from Socialtext Wikis|
|''Author:''|Martin Budden (mjbudden (at) gmail (dot) com) and JeremyRuston (jeremy (at) osmosoft (dot) com)|
|''Source:''|http://www.martinswiki.com/#SocialtextAdaptorPlugin|
|''CodeRepository:''|http://svn.tiddlywiki.org/Trunk/contributors/MartinBudden/adaptors/SocialtextAdaptorPlugin.js|
|''Version:''|0.5.1|
|''Date:''|Feb 25, 2007|
|''Comments:''|Please make comments at http://groups.google.co.uk/group/TiddlyWikiDev|
|''License:''|[[Creative Commons Attribution-ShareAlike 2.5 License|http://creativecommons.org/licenses/by-sa/2.5/]]|
|''~CoreVersion:''|2.2.0|
Socialtext REST documentation is at:
http://www.eu.socialtext.net/st-rest-docs/index.cgi?socialtext_rest_documentation
***/
//{{{
if(!version.extensions.SocialtextAdaptorPlugin) {
version.extensions.SocialtextAdaptorPlugin = {installed:true};
function SocialtextAdaptor()
{
this.host = null;
this.workspace = null;
return this;
}
SocialtextAdaptor.mimeType = 'text/x.socialtext-wiki';
SocialtextAdaptor.serverType = 'socialtext';
SocialtextAdaptor.serverParsingErrorMessage = "Error parsing result from server";
SocialtextAdaptor.errorInFunctionMessage = "Error in function SocialtextAdaptor.%0";
SocialtextAdaptor.prototype.setContext = function(context,userParams,callback)
{
if(!context) context = {};
context.userParams = userParams;
if(callback) context.callback = callback;
context.adaptor = this;
if(!context.host)
context.host = this.host;
if(!context.workspace && this.workspace)
context.workspace = this.workspace;
return context;
};
SocialtextAdaptor.doHttpGET = function(uri,callback,params,headers,data,contentType,username,password)
{
return doHttp('GET',uri,data,contentType,username,password,callback,params,headers);
};
SocialtextAdaptor.doHttpPOST = function(uri,callback,params,headers,data,contentType,username,password)
{
return doHttp('POST',uri,data,contentType,username,password,callback,params,headers);
};
SocialtextAdaptor.fullHostName = function(host)
{
if(!host)
return '';
if(!host.match(/:\/\//))
host = 'http://' + host;
if(host.substr(host.length-1) != '/')
host = host + '/';
return host;
};
SocialtextAdaptor.minHostName = function(host)
{
return host ? host.replace(/^http:\/\//,'').replace(/\/$/,'') : '';
};
// Convert a page title to the normalized form used in uris
SocialtextAdaptor.normalizedTitle = function(title)
{
var n = title.toLowerCase();
n = n.replace(/\s/g,'_').replace(/\//g,'_').replace(/\./g,'_').replace(/:/g,'').replace(/\?/g,'');
if(n.charAt(0)=='_')
n = n.substr(1);
return String(n);
};
// Convert a Socialtext date in YYYY-MM-DD hh:mm format into a JavaScript Date object
SocialtextAdaptor.dateFromEditTime = function(editTime)
{
var dt = editTime;
return new Date(Date.UTC(dt.substr(0,4),dt.substr(5,2)-1,dt.substr(8,2),dt.substr(11,2),dt.substr(14,2)));
};
SocialtextAdaptor.prototype.openHost = function(host,context,userParams,callback)
{
this.host = SocialtextAdaptor.fullHostName(host);
context = this.setContext(context,userParams,callback);
if(context.callback) {
context.status = true;
window.setTimeout(function() {callback(context,userParams);},0);
}
return true;
};
SocialtextAdaptor.prototype.openWorkspace = function(workspace,context,userParams,callback)
{
this.workspace = workspace;
context = this.setContext(context,userParams,callback);
if(context.callback) {
context.status = true;
window.setTimeout(function() {callback(context,userParams);},0);
}
return true;
};
SocialtextAdaptor.prototype.getWorkspaceList = function(context,userParams,callback)
{
context = this.setContext(context,userParams,callback);
var uriTemplate = '%0data/workspaces';
var uri = uriTemplate.format([context.host]);
var req = SocialtextAdaptor.doHttpGET(uri,SocialtextAdaptor.getWorkspaceListCallback,context,{'accept':'application/json'});
return typeof req == 'string' ? req : true;
};
SocialtextAdaptor.getWorkspaceListCallback = function(status,context,responseText,uri,xhr)
{
context.status = false;
context.statusText = SocialtextAdaptor.errorInFunctionMessage.format(['getWorkspaceListCallback']);
if(status) {
try {
eval('var info=' + responseText);
} catch (ex) {
context.statusText = exceptionText(ex,SocialtextAdaptor.serverParsingErrorMessage);
if(context.callback)
context.callback(context,context.userParams);
return;
}
var list = [];
for(var i=0; i<info.length; i++) {
var item = {
title:info[i].title,
name:info[i].name,
modified:SocialtextAdaptor.dateFromEditTime(info[i].modified_time)
};
list.push(item);
}
context.workspaces = list;
context.status = true;
} else {
context.statusText = xhr.statusText;
}
if(context.callback)
context.callback(context,context.userParams);
};
SocialtextAdaptor.prototype.getTiddlerList = function(context,userParams,callback)
{
context = this.setContext(context,userParams,callback);
var uriTemplate = '%0data/workspaces/%1/pages?order=newest';//!! ? or ;
var uri = uriTemplate.format([context.host,context.workspace]);
var req = SocialtextAdaptor.doHttpGET(uri,SocialtextAdaptor.getTiddlerListCallback,context,{'accept':'application/json'});
return typeof req == 'string' ? req : true;
};
SocialtextAdaptor.getTiddlerListCallback = function(status,context,responseText,uri,xhr)
{
context.status = false;
context.statusText = SocialtextAdaptor.errorInFunctionMessage.format(['getTiddlerListCallback']);
if(status) {
try {
eval('var info=' + responseText);
} catch (ex) {
context.statusText = exceptionText(ex,SocialtextAdaptor.serverParsingErrorMessage);
if(context.callback)
context.callback(context,context.userParams);
return;
}
var list = [];
for(var i=0; i<info.length; i++) {
var tiddler = new Tiddler(info[i].name);
tiddler.modified = SocialtextAdaptor.dateFromEditTime(info[i].last_edit_time);
tiddler.modifier = info[i].last_editor;
tiddler.tags = info[i].tags;
tiddler.fields['server.page.id'] = info[i].page_id;
tiddler.fields['server.page.name'] = info[i].name;
tiddler.fields['server.page.revision'] = String(info[i].revision_id);
list.push(tiddler);
}
context.tiddlers = list;
context.status = true;
} else {
context.statusText = xhr.statusText;
}
if(context.callback)
context.callback(context,context.userParams);
};
SocialtextAdaptor.prototype.generateTiddlerInfo = function(tiddler)
{
var info = {};
var host = this && this.host ? this.host : SocialtextAdaptor.fullHostName(tiddler.fields['server.host']);
var workspace = this && this.workspace ? this.workspace : tiddler.fields['server.workspace'];
uriTemplate = '%0%1/index.cgi?%2';
info.uri = uriTemplate.format([host,workspace,SocialtextAdaptor.normalizedTitle(tiddler.title)]);
return info;
};
SocialtextAdaptor.prototype.getTiddler = function(title,context,userParams,callback)
{
return this.getTiddlerRevision(title,null,context,userParams,callback);
};
SocialtextAdaptor.prototype.getTiddlerRevision = function(title,revision,context,userParams,callback)
{
context = this.setContext(context,userParams,callback);
// request the page in json format to get the page attributes
if(revision) {
var uriTemplate = '%0data/workspaces/%1/pages/%2/revisions/%3';
context.revision = revision;
} else {
uriTemplate = '%0data/workspaces/%1/pages/%2';
context.revision = null;
}
uri = uriTemplate.format([context.host,context.workspace,SocialtextAdaptor.normalizedTitle(title),revision]);
context.tiddler = new Tiddler(title);
context.tiddler.fields.wikiformat = 'socialtext';
context.tiddler.fields['server.host'] = SocialtextAdaptor.minHostName(context.host);
context.tiddler.fields['server.workspace'] = context.workspace;
var req = SocialtextAdaptor.doHttpGET(uri,SocialtextAdaptor.getTiddlerCallback,context,{'accept':'application/json'});
return typeof req == 'string' ? req : true;
};
SocialtextAdaptor.getTiddlerCallback = function(status,context,responseText,uri,xhr)
{
context.status = false;
context.statusText = SocialtextAdaptor.errorInFunctionMessage.format(['getTiddlerCallback']);
if(status) {
try {
eval('var info=' + responseText);
context.tiddler.tags = info.tags;
context.tiddler.fields['server.page.id'] = info.page_id;
context.tiddler.fields['server.page.name'] = info.name;
context.tiddler.fields['server.page.revision'] = String(info.revision_id);
context.tiddler.modifier = info.last_editor;
context.tiddler.modified = SocialtextAdaptor.dateFromEditTime(info.last_edit_time);
} catch (ex) {
context.statusText = exceptionText(ex,SocialtextAdaptor.serverParsingErrorMessage);
if(context.callback)
context.callback(context,context.userParams);
return;
}
context.status = true;
} else {
context.statusText = xhr.statusText;
if(context.callback)
context.callback(context,context.userParams);
return;
}
var uriTemplate = context.revision ? '%0data/workspaces/%1/pages/%2/revisions/%3' : '%0data/workspaces/%1/pages/%2';
var host = SocialtextAdaptor.fullHostName(context.tiddler.fields['server.host']);
var workspace = context.workspace ? context.workspace : context.tiddler.fields['server.workspace'];
uri = uriTemplate.format([host,workspace,SocialtextAdaptor.normalizedTitle(context.tiddler.title),context.revision]);
var req = SocialtextAdaptor.doHttpGET(uri,SocialtextAdaptor.getTiddlerCallback2,context,{'accept':SocialtextAdaptor.mimeType});
};
SocialtextAdaptor.getTiddlerCallback2 = function(status,context,responseText,uri,xhr)
{
context.tiddler.text = responseText;
if(status) {
context.status = true;
} else {
context.status = false;
context.statusText = xhr.statusText;
}
if(context.callback)
context.callback(context,context.userParams);
};
SocialtextAdaptor.prototype.getTiddlerRevisionList = function(title,limit,context,userParams,callback)
{
context = this.setContext(context,userParams,callback);
var uriTemplate = '%0data/workspaces/%1/pages/%2/revisions?accept=application/json';
if(!limit)
limit = 5;
var uri = uriTemplate.format([context.host,context.workspace,SocialtextAdaptor.normalizedTitle(title),limit]);
var req = SocialtextAdaptor.doHttpGET(uri,SocialtextAdaptor.getTiddlerRevisionListCallback,context);
return typeof req == 'string' ? req : true;
};
SocialtextAdaptor.getTiddlerRevisionListCallback = function(status,context,responseText,uri,xhr)
{
context.status = false;
if(status) {
var content = null;
try {
eval('var info=' + responseText);
} catch (ex) {
context.statusText = exceptionText(ex,SocialtextAdaptor.serverParsingErrorMessage);
if(context.callback)
context.callback(context,context.userParams);
return;
}
list = [];
for(var i=0; i<info.length; i++) {
var tiddler = new Tiddler(info[i].name);
tiddler.modified = SocialtextAdaptor.dateFromEditTime(info[i].last_edit_time);
tiddler.modifier = info[i].last_editor;
tiddler.tags = info[i].tags;
tiddler.fields['server.page.id'] = info[i].page_id;
tiddler.fields['server.page.name'] = info[i].name;
tiddler.fields['server.page.revision'] = info[i].revision_id;
list.push(tiddler);
}
var sortField = 'server.page.revision';
list.sort(function(a,b) {return a.fields[sortField] < b.fields[sortField] ? +1 : (a.fields[sortField] == b.fields[sortField] ? 0 : -1);});
context.revisions = list;
context.status = true;
} else {
context.statusText = xhr.statusText;
}
if(context.callback)
context.callback(context,context.userParams);
};
SocialtextAdaptor.prototype.putTiddler = function(tiddler,context,userParams,callback)
{
context = this.setContext(context,userParams,callback);
context.tiddler = tiddler;
context.title = tiddler.title;
var uriTemplate = '%0data/workspaces/%1/pages/%2';
var host = context.host ? context.host : SocialtextAdaptor.fullHostName(tiddler.fields['server.host']);
var workspace = context.workspace ? context.workspace : tiddler.fields['server.workspace'];
var uri = uriTemplate.format([host,workspace,tiddler.title,tiddler.text]);
//var req = doHttp('POST',uri,tiddler.text,SocialtextAdaptor.mimeType,null,null,SocialtextAdaptor.putTiddlerCallback,context,{"X-Http-Method": "PUT"});
var req = SocialtextAdaptor.doHttpPOST(uri,SocialtextAdaptor.putTiddlerCallback,context,{"X-Http-Method": "PUT"},tiddler.text,SocialtextAdaptor.mimeType);
return typeof req == 'string' ? req : true;
};
SocialtextAdaptor.putTiddlerCallback = function(status,context,responseText,uri,xhr)
{
if(status) {
context.status = true;
} else {
context.status = false;
context.statusText = xhr.statusText;
}
if(context.callback)
context.callback(context,context.userParams);
};
SocialtextAdaptor.prototype.close = function()
{
return true;
};
config.adaptors[SocialtextAdaptor.serverType] = SocialtextAdaptor;
} //# end of 'install only once'
//}}}
/***
SocialtextStyleOverrides
***/
/*{{{*/
.headerShadow {padding: 2em 0em .5em 1em;}
.headerForeground {padding: 2em 0em .5em 1em;}
#st-page-wiki-title {
font-size: 80%;
}
.subtitle {
font-style: italic;
font-size 80%;
}
/* from #st-tags */
.tagged {
border-color: #bbeebb;
background-color: #f4fff4;
}
.tagged .listTitle {
color: #595;
font-weight: bold;
}
.tagged .button {
color: #000;
}
.selected .tagged {
background-color: ColorPalette::TertiaryLight;
border: 1px solid ColorPalette::TertiaryMid;
}
/* from #st-incoming-links */
.tagging {
border-color: #ebb;
background-color: #fff4f4;
}
.tagging .listTitle {
color: #b78;
font-weight: bold;
}
.tagging .button {
color: #999;
}
.selected .tagging {
background-color: ColorPalette::TertiaryLight;
border: 1px solid ColorPalette::TertiaryMid;
}
.tiddler {/* Tiddler body */
border:1px solid #ccc;
margin:0.5em;
background:#fff;
padding:0.5em;
}
.viewer blockquote {border-left: 0px solid}
.tiddlyLinkNonExisting {
font-style: italic;
border-bottom: 1px dashed;
}
.editor input, .editor textarea {
background: #ffd;
border-style: solid;
border-color: #888 #ccc #ccc #888;
border-width: 2px;
}
.tabContents {white-space: nowrap;}
#displayArea {margin: 1em 20em 0em 14em;}
#sidebar {
position: absolute;
right: 3px;
width: 21em;
font-size: .9em;
}
#sidebarOptions .button {
border-color: #eee;
}
#sidebarTabs .tabContents {
width: 20em;
overflow: hidden;
}
.viewer tt {
font-size: 1.2em;
line-height: 1.4em;
}
ul {list-style-type: square;}
ul ul {list-style-type: circle;}
ol {list-style-type: decimal;}
ol ol {list-style-type: decimal;}
ol ol ol {list-style-type: decimal;}
ol ol ol ol {list-style-type: decimal;}
ol ol ol ol ol {list-style-type: decimal;}
ol ol ol ol ol ol {list-style-type: decimal;}
/*}}}*/
/***
SocialtextScreenStyle
http://www.eu.socialtext.net/static/2.0.0.1/css/st/screen.css
***/
/*{{{*/
body {
font-family: Arial, sans-serif;
color: #000;
background: #eee;
margin: 0;
}
/* Wiki Navigation */
.st-wiki-nav {
clear: both;
margin-left: 10px;
margin-right: 10px;
}
.st-wiki-nav-content {
background: url('../../images/st/wiki-nav/solid.gif') repeat-x left bottom;
margin-left: 24px;
margin-right: 24px;
padding-top: 3px;
min-height: 24px;
}
* html .st-wiki-nav-content {
padding-bottom: 3px;
height: 24px;
}
.st-wiki-nav-right {
background: url('../../images/st/wiki-nav/right-round.gif') no-repeat bottom right;
}
.st-wiki-nav-left {
background: url('../../images/st/wiki-nav/left-round.gif') no-repeat bottom left;
}
#st-home {
float: left;
margin-right: 60px;
padding-top: 2px;
}
#st-home-link {
color: white;
text-decoration: none;
font-weight: bold;
font-family: Helvetica, sans-serif;
font-size: 90%;
}
#st-editing-prefix-container {
border-collapse: collapse;
width: 100%;
padding: 0px;
margin: 0px;
margin-bottom: -20px;
}
#st-editing-prefix-container tr td {
margin: 0px;
padding: 0px;
}
#st-editing-title {
color: black;
background-color: white;
text-decoration: none;
font-weight: bold;
font-family: Helvetica, sans-serif;
font-size: 90%;
margin-bottom: 0.4em;
}
#st-wiki-title-invite {
font-size: 50%;
font-family: Helvetica, sans-serif;
}
#st-wiki-title-central-page-link {
font-size: 50%;
font-family: Helvetica, sans-serif;
}
#st-wiki-title-invite a {
color: #00f;
}
#st-wiki-logo {
text-align: center;
clear: both;
}
#st-wiki-logo-image {
}
.st-wiki-nav-actions {
float: right;
color: black;
font-size: 75%;
padding-top: 3px;
}
.st-wiki-nav-actions a {
padding: 2px;
color: white;
text-decoration: none;
font-family: Helvetica, sans-serif;
}
/* Wiki Subnav */
#st-wiki-subnav {
margin-top: 2px;
font-size: 70%;
font-weight: bold;
font-family: Helvetica, sans-serif;
color: #888;
}
#st-wiki-subnav a {
padding: 2px;
color: #008;
text-decoration: none;
}
#st-wiki-subnav-right {
float: right;
margin-right: 6em;
}
#st-wiki-subnav-left {
float: left;
margin-left: 6em;
}
* html #st-wiki-subnav-left {
margin-left: 3em;
}
/* Wiki Navigation Search Bar */
#st-search-form {
margin: 0;
padding: 0;
padding-top: 1px;
}
#st-search-form .button-table {
float: left;
font-size: 79%;
font-weight: bold;
margin-left: 5px;
margin-top: 1px;
}
#st-search-form #st-search-term {
float: left;
font-size: 60%;
}
/* Content Outline */
#st-content-border, #st-edit-border {
position: relative;
clear: both;
margin-left: 3px;
margin-right: 2px;
margin-bottom: 0px;
margin-top: 0px;
border-bottom: 1px solid #eee;
}
#st-content-border-left, #st-edit-border-left {
background: url('../../images/st/page-shadow/left.gif') left top repeat-y;
position: relative;
}
#st-content-border-right, #st-edit-border-right {
background: url('../../images/st/page-shadow/right.gif') right top repeat-y;
position: relative;
}
#st-content-border-top, #st-edit-border-top {
position: relative;
background: url('../../images/st/page-shadow/top.gif') left top repeat-x;
}
#st-content-border-bottom, #st-edit-border-bottom {
background: url('../../images/st/page-shadow/bottom.gif') left bottom repeat-x;
position: relative;
}
#st-content-border-left-top, #st-edit-border-left-top {
background: url('../../images/st/page-shadow/left-top.gif') left top no-repeat;
position: relative;
}
#st-content-border-right-top, #st-edit-border-right-top {
background: url('../../images/st/page-shadow/right-top.gif') right top no-repeat;
position: relative;
}
#st-content-border-left-bottom, #st-edit-border-left-bottom {
background: url('../../images/st/page-shadow/left-bottom.gif') left bottom no-repeat;
position: relative;
}
#st-content-border-right-bottom, #st-edit-border-right-bottom {
background: url('../../images/st/page-shadow/right-bottom.gif') right bottom no-repeat;
padding-top: 5px;
padding-bottom: 9px;
position: relative;
}
* html #st-content-border-right-bottom, * html #st-edit-border-right-bottom {
padding-top: 4px;
padding-left: 7px;
padding-right: 8px;
position: relative;
}
.st-content-width-controller {
width: 100%;
position: relative;
border-collapse: collapse;
}
.st-content-width-controller td {
vertical-align: top;
}
.st-content {
position: relative;
background-color: white;
margin-top: 0px;
margin-left: 7px;
margin-right: 8px;
margin-bottom: -1px;
border-left: 1px dotted #80a9f3;
border-right: 1px dotted #80a9f3;
border: 1px solid #80a9f3;
padding: 6px 12px 12px 12px;
}
* html .st-content {
margin-top: 0px;
margin-left: 0px;
margin-right: 0px;
}
/* This textarea is only for Safari. However, if we use display:none; here Safari ignores the .value operation in JS */
#st-raw-wikitext-textarea {
width:1px;
height:1px;
margin:0;
padding:0;
}
/* Action Buttons */
.button-table, .button-table tr td {
border-collapse: collapse;
margin: 0;
padding: 0;
}
.button-rounded {
background: url('../../images/st/grey-button/left-top-rounded.png') top left no-repeat;
margin: 0;
}
.button-rounded-right-top {
background: url('../../images/st/grey-button/right-top-rounded.png') top right no-repeat;
margin: 0;
}
.button-rounded-left-bottom {
background: url('../../images/st/grey-button/left-bottom-rounded.png') bottom left no-repeat;
margin: 0;
}
.button-rounded-right-bottom {
background: url('../../images/st/grey-button/right-bottom-rounded.png') bottom right no-repeat;
margin: 0;
}
.button-straight {
background: url('../../images/st/grey-button/left-top-straight.png') top left no-repeat;
margin: 0;
}
.button-straight-right-top {
background: url('../../images/st/grey-button/right-top-straight.png') top right no-repeat;
margin: 0;
}
.button-straight-left-bottom {
background: url('../../images/st/grey-button/left-bottom-straight.png') bottom left no-repeat;
margin: 0;
}
.button-straight-right-bottom {
background: url('../../images/st/grey-button/right-bottom-straight.png') bottom right no-repeat;
margin: 0;
}
.button-content {
font-size: 90%;
}
.button-content a {
display: block;
padding: 2px;
padding-left: 10px;
padding-right: 10px;
font-family: Helvetica, Verdana, sans-serif;
font-weight: bold;
text-decoration: none;
color: black;
}
.button-content input.submit {
border: 0px;
padding: 2px;
padding-left: 10px;
padding-right: 10px;
font-family: Helvetica, Verdana, sans-serif;
font-weight: bold;
text-decoration: none;
color: black;
background-color: transparent;
}
/* Personal Homepage */
#st-homepage {
background: white url('../../images/st/homepage/blue-fade.gif') top left no-repeat;
}
#st-homepage-layout {
margin-top: 15px;
clear: both;
width: 100%;
border-collapse: collapse;
}
#st-homepage-layout tr td.st-homepage-layout-cell {
padding: 5px;
vertical-align: top;
}
#st-homepage-layout-dashboard {
width: 50%
}
#st-homepage-layout-notes {
width: 50%;
}
#st-homepage-notes, #st-homepage-dashboard {
text-align: left;
width: 95%;
}
#st-user-greeting, #st-wiki-title {
font-family: Helvetica, Verdana, sans-serif;
font-size: 150%;
}
#st-wiki-title {
margin-left: 5px;
}
#st-user-greeting {
position: relative;
text-align: right;
float: right;
}
#st-group-notes-content, #st-personal-notes-content {
}
.st-homepage-section {
margin-bottom: 15px;
}
#st-homepage-notes .st-homepage-section {
background-color: white;
border: 1px solid #aaa;
padding: 15px;
}
.st-homepage-section-title {
font-size: 110%;
font-family: Helvetica, Verdana, sans-serif;
}
#st-homepage-notes .st-homepage-section-title {
color: #aaa;
text-decoration: underline;
}
.st-homepage-notes-edit-link {
background: url('../../images/st/homepage/edit-icon.gif') no-repeat left top;
display: block;
text-indent: -2000px;
height: 13px;
width: 36px;
text-decoration: none;
padding:0;
}
* html .st-homepage-notes-edit-link {
border:1px solid white;
}
.st-homepage-notes-edit {
font-family: Verdana, sans-serif;
font-size: 65%;
float: right;
}
.st-homepage-notes-content {
font-size: 85%;
margin-top: 10px;
padding-top: 0px;
padding-bottom: 0px;
font-family: Verdana, Helvetica, sans-serif;
}
#st-dyk {
border-color: #cca !important;
background-color: #ffe !important;
}
#st-dyk-title {
color: #e4a020 !important;
text-decoration: none !important;
}
/* Homepage Simple List */
#st-whats-new-title-link {
background: url('../../images/st/homepage/icon-28-pages.gif') no-repeat left top;
}
#st-watchlist-title-link {
background: url('../../images/st/homepage/icon-28-star.gif') no-repeat left top;
}
#st-wikis-title-link {
background: url('../../images/st/homepage/icon-28-group.gif') no-repeat left top;
}
.st-homepage-simplelist-title-link {
display: block;
padding-left: 32px;
min-height: 32px;
}
* html .st-homepage-simplelist-title-link {
height: 32px;
}
.st-homepage-simplelist-title {
}
.st-homepage-simplelist-table {
margin-left: 25px;
border: 1px dashed #ddd;
border-collapse: collapse;
font-family: Verdana, Helvetica, sans-serif;
font-size: 80%;
width: 95%;
}
.st-homepage-simplelist-table td {
padding: 2px;
}
.st-homepage-simplelist-table tr.st-homepage-simplelist-row-odd {
background-color: #f3f7f7;
}
.st-homepage-simplelist-table tr.st-homepage-simplelist-row-even {
background-color: white;
}
.st-homepage-simplelist-table a {
color: #4f55dd;
text-decoration: none;
}
.st-homepage-simplelist-table a:visited {
color: #551a8b;
}
.st-homepage-simplelist-subleft {
font-size: 80%;
margin-left: 1em;
color: #666;
}
.st-homepage-simplelist-right {
width: 20%;
}
.st-homepage-simplelist-subright {
font-size: 80%;
color: #666;
}
.st-homepage-simplelist {
}
.st-homepage-simplelist-header {
min-height: 35px;
}
.st-homepage-simplelist-header .button-table {
float: right;
margin-right: 15px;
font-size: 95%;
}
.st-homepage-simplelist-header .button-table .button-content {
padding: 1px;
}
.st-homepage-whatsnew-author, .st-homepage-whatsnew-date {
color: #555;
}
.st-homepage-whatsnew-attribution {
padding-left: 1em;
font-size: 80%;
color: #aaa;
}
/* Homepage Wikis List */
#st-wikis-title {
}
/* Data and Templates */
.st-jst-template, .st-json {
display: none;
}
/* Page Sidebox Common Styles */
#st-page-boxes-toggle {
position: relative;
float: right;
text-align: right;
font-family: Verdana, Arial, sans-serif;
font-weight: bold;
font-size: 80%;
margin-bottom: 0.7em;
}
#st-page-boxes-toggle-link {
text-decoration: none;
}
#st-page-boxes-underlay {
float: right;
margin-top: -10px;
margin-right: 10px;
background: white;
z-index: 198;
clear: both;
margin-left: 15px;
}
* html #st-page-boxes-underlay {
margin-right: 4px;
}
#st-page-boxes {
background: inherit;
position: absolute;
right: 23px;
z-index: 199;
margin-top: 15px;
margin-left: 20px;
}
#st-page-boxes, #st-page-boxes-underlay {
width: 225px;
/* padding-left: 15px; */ /* Gives the white border effect, cwest dislikes it. */
}
.st-page-box {
border: 1px solid black;
padding: 5px;
font-family: Verdana, Helvetica, sans-serif;
font-size: 80%;
margin-top: 15px;
}
.st-page-box-title {
font-family: Helvetica, Verdana, sans-serif;
font-weight: bold;
margin-bottom: 10px;
}
.st-page-box-listing {
margin: 0;
padding: 0;
}
.st-page-box-listing-entry {
display: block;
}
.st-page-boxes-nobacklinks {
font-family: Verdana, Helvetica, sans-serif;
font-size: 90%;
color: #888;
}
.st-page-box-first {
margin-top: 0px;
}
/* Page Display */
#st-page-content {
clear: left;
margin-top: 6px;
margin-bottom: 0;
padding-bottom: 0;
}
#st-page-content, #st-page-content td {
font-family: Verdana, Helvetica, sans-serif;
font-size: 90%;
}
#st-page-wiki-title {
font-family: Helvetica, Verdana, sans-serif;
font-size: 65%;
font-weight: bold;
color: #aaa;
margin-bottom: 0.2em;
margin-top: 0.1em;
padding-top: 0;
}
#wiki {
margin: 0;
padding: 0;
}
#st-page-title {
}
#st-page-titletext, .st-page-title {
font-family: Helvetica, Verdana, sans-serif;
font-size: 150%;
font-weight: bold;
color: #888;
border-bottom: 1px solid #888;
}
#st-newpage-pagename-edit {
font-family: inherit;
font-size: inherit;
font-weight: inherit;
color: #000;
border: 1px solid black;
padding-left: 0.3em;
background-color: #ffd;
}
#st-page-details {
font-style: italic;
font-size: 75%;
font-family: Georgia, serif;
margin: 6px 10px 0 10px;
}
#st-page-details-feed-icon {
vertical-align: middle;
border: none;
}
#st-page-stats {
float: right;
vertical-align: middle;
}
#st-attribution {
float: left;
margin-bottom: 10px;
}
#st-page-editing-wysiwyg {
background: #ffd;
border-style: solid;
border-color: #888 #ccc #ccc #888;
border-width: 2px;
width: 100%;
}
#st-page-editing-toolbar {
margin-left: -6px;
overflow: hidden;
float: left;
height: 25px;
}
#wikiwyg_wikitext_textarea {
margin-top: 4px;
background: #ffd;
border-style: solid;
border-color: #888 #ccc #ccc #888;
border-width: 2px;
width: 100%;
font-family: monospace;
}
#st-page-maincontent {
}
#st-page-editing, #wikiwyg_wikitext_textarea {
}
#st-page-editing-pagebody-decoy, #st-page-editing-wysiwyg {
display: none;
}
#st-editing-tools-edit {
display: none;
}
#st-mode-wysiwyg-button
{
font-size: 70%;
margin-left: 4em;
}
#st-mode-wikitext-button
{
font-size: 70%;
}
#st-edit-tips
{
font-size: 70%;
}
.wikiwyg_button {
background: #FFFFFF;
border: 1px solid #FFFFFF;
cursor: pointer;
width: 20px;
height: 20px;
vertical-align: bottom;
}
.wikiwyg_button:hover {
border: 1px outset;
}
.wikiwyg_button:active {
border: 1px inset;
}
#wikiwyg_toolbar {
display: none;
}
/* Sidebox Pagetools: Revisions, Watchlist */
#st-side-box-pagetools {
border-collapse: collapse;
}
#st-rewind-norevisions {
font-family: Helvetica, Arial, sans-serif;
font-size: 11px;
color: #777;
text-decoration: none;
}
#st-side-box-pagetools a {
font-family: Helvetica, Arial, sans-serif;
font-size: 11px;
color: #555;
text-decoration: none;
}
/* Page View Tags/Incoming Links Sidebox */
#st-tags {
background: #f4fff4;
border-color: #bbeebb;
color: #999;
}
#st-tags-title {
color: #595;
}
#st-tags-addlink, #st-tags-addbutton {
font-weight: bold;
}
#st-tags-listing {
margin-bottom: 5px;
}
#st-tags-addinput, #st-tags-message, #st-tags-suggestion {
display: none;
}
#st-tags-deletemessage {
font-size: 90%;
color: #555;
display: none;
margin-top: 0.5em;
margin-bottom: 0.5em;
}
#st-tags-suggestion {
margin-top: 2px;
}
.st-tags-level1 {
font-size: 90%;
}
.st-tags-level2 {
font-size: 100%;
}
.st-tags-level3 {
font-size: 110%;
}
.st-tags-level4 {
font-size: 120%;
}
.st-tags-level5 {
font-size: 130%;
}
.st-tags-tagline .st-tags-tagdelete {
text-decoration: none;
color: #ccc;
}
.st-tags-tagline a {
text-decoration: none;
color: #444;
}
#st-tags-field {
width: 95%;
}
#st-incoming-links {
border-color: #ebb;
background-color: #fff4f4;
}
#st-incoming-links-title {
color: #b78;
}
#st-attachments {
border-color: #bbe;
background-color: #f4f4ff;
}
#st-attachments-uploadbutton, #st-attachments-managebutton {
}
#st-attachments-buttons-uploadbutton {
margin: 0px;
padding: 0px;
padding-left: 2px;
}
#st-attachments-buttons-managebutton {
margin: 0px;
padding: 0px;
padding-right: 2px;
}
#st-attachments-buttons td {
padding-right: 3px;
font-size: 99%;
}
#st-attachments-buttons {
border-collapse: collapse;
margin: 0px;
padding: 0px;
margin-top: 5px;
}
#st-attachments-title {
color: #77b;
}
.st-attachments-line {
width:100%;
overflow:hidden;
}
/* Actions Bar */
#st-actions-bar-spacer {
clear:both;
height:0.5em;
overflow:hidden;
}
#st-actions-bar-spacer-clear {
clear:both;
height:1px;
overflow:hidden;
}
#st-actions-bar, #st-editing-tools-bar {
margin-left: 30px !important;
margin-right: 30px !important;
}
/* Footer */
#st-footer {
margin-top: -8px;
margin-bottom: 5px;
clear: both;
}
/* Socialtext Attribution */
#st-socialtext-attribution {
clear: both;
text-align: center;
font-size: 80%;
font-family: Helvetica, sans-serif;
}
#st-socialtext-attribution-link {
text-decoration: none;
}
#st-socialtext-attribution-image {
border: 0;
}
/* Page Actions */
#st-edit-button-border-left-middle, #st-login-to-edit-button-border-left-middle {
background: url('../../images/st/button-blue/left-middle.gif') left top repeat-y;
}
#st-edit-button-border-right-middle, #st-login-to-edit-button-border-right-middle {
background: url('../../images/st/button-blue/right-middle.gif') right top repeat-y;
}
#st-edit-button-border-left-top, #st-login-to-edit-button-border-left-top {
background: url('../../images/st/button-blue/left-top.gif') left top no-repeat;
}
#st-edit-button-border-right-top, #st-login-to-edit-button-border-right-top {
background: url('../../images/st/button-blue/right-top.gif') right top no-repeat;
}
#st-edit-button-border-left-bottom, #st-login-to-edit-button-border-left-bottom {
background: url('../../images/st/button-blue/left-bottom.gif') left bottom no-repeat;
}
#st-edit-button-border-right-bottom, #st-login-to-edit-button-border-right-bottom {
background: url('../../images/st/button-blue/right-bottom.gif') right bottom no-repeat;
}
#st-edit-button-link, #st-login-to-edit-button-link {
}
#st-comment-button-border-left-middle {
background: url('../../images/st/button-purple/left-middle.gif') left top repeat-y;
}
#st-comment-button-border-right-middle {
background: url('../../images/st/button-purple/right-middle.gif') right top repeat-y;
}
#st-comment-button-border-left-top {
background: url('../../images/st/button-purple/left-top.gif') left top no-repeat;
}
#st-comment-button-border-right-top {
background: url('../../images/st/button-purple/right-top.gif') right top no-repeat;
}
#st-comment-button-border-left-bottom {
background: url('../../images/st/button-purple/left-bottom.gif') left bottom no-repeat;
}
#st-comment-button-border-right-bottom {
background: url('../../images/st/button-purple/right-bottom.gif') right bottom no-repeat;
}
#st-comment-button-link {
}
#st-save-button-border-left-middle {
background: url('../../images/st/button-green/left-middle.gif') left top repeat-y;
}
#st-save-button-border-right-middle {
background: url('../../images/st/button-green/right-middle.gif') right top repeat-y;
}
#st-save-button-border-left-top {
background: url('../../images/st/button-green/left-top.gif') left top no-repeat;
}
#st-save-button-border-right-top {
background: url('../../images/st/button-green/right-top.gif') right top no-repeat;
}
#st-save-button-border-left-bottom {
background: url('../../images/st/button-green/left-bottom.gif') left bottom no-repeat;
}
#st-save-button-border-right-bottom {
background: url('../../images/st/button-green/right-bottom.gif') right bottom no-repeat;
}
#st-save-button-link {
}
#st-preview-button-border-left-middle {
background: url('../../images/st/button-gold/left-middle.gif') left top repeat-y;
}
#st-preview-button-border-right-middle {
background: url('../../images/st/button-gold/right-middle.gif') right top repeat-y;
}
#st-preview-button-border-left-top {
background: url('../../images/st/button-gold/left-top.gif') left top no-repeat;
}
#st-preview-button-border-right-top {
background: url('../../images/st/button-gold/right-top.gif') right top no-repeat;
}
#st-preview-button-border-left-bottom {
background: url('../../images/st/button-gold/left-bottom.gif') left bottom no-repeat;
}
#st-preview-button-border-right-bottom {
background: url('../../images/st/button-gold/right-bottom.gif') right bottom no-repeat;
}
#st-preview-button-link {
}
#st-cancel-button-border-left-middle {
background: url('../../images/st/button-crimson/left-middle.gif') left top repeat-y;
}
#st-cancel-button-border-right-middle {
background: url('../../images/st/button-crimson/right-middle.gif') right top repeat-y;
}
#st-cancel-button-border-left-top {
background: url('../../images/st/button-crimson/left-top.gif') left top no-repeat;
}
#st-cancel-button-border-right-top {
background: url('../../images/st/button-crimson/right-top.gif') right top no-repeat;
}
#st-cancel-button-border-left-bottom {
background: url('../../images/st/button-crimson/left-bottom.gif') left bottom no-repeat;
}
#st-cancel-button-border-right-bottom {
background: url('../../images/st/button-crimson/right-bottom.gif') right bottom no-repeat;
}
#st-cancel-button-link {
}
#st-edit-more-button-border-left-middle {
background: url('../../images/st/button-blue/left-middle.gif') left top repeat-y;
}
#st-edit-more-button-border-right-middle {
background: url('../../images/st/button-blue/right-middle.gif') right top repeat-y;
}
#st-edit-more-button-border-left-top {
background: url('../../images/st/button-blue/left-top.gif') left top no-repeat;
}
#st-edit-more-button-border-right-top {
background: url('../../images/st/button-blue/right-top.gif') right top no-repeat;
}
#st-edit-more-button-border-left-bottom {
background: url('../../images/st/button-blue/left-bottom.gif') left bottom no-repeat;
}
#st-edit-more-button-border-right-bottom {
background: url('../../images/st/button-blue/right-bottom.gif') right bottom no-repeat;
}
#st-edit-more-button-link {
}
.st-page-action-button-link {
min-height: 24px;
min-width: 100px;
text-align: center;
font-family: Helvetica, Verdana, sans-serif;
font-size: 90%;
text-decoration: none;
color: #fff;
font-weight: bold;
display: block;
padding-top: 8px;
padding-bottom: 0px;
margin-bottom: -3px;
width: 100%;
margin-left: -2px;
}
* html .st-page-action-button-link {
padding-top: 5px;
padding-bottom: 0px;
height: 24px;
}
.st-page-action-button {
float: left;
margin: 0;
padding: 0;
margin-right: 10px;
min-height: 20px;
border-collapse: collapse;
width: 100px;
}
/* Attach File Interface */
#st-attachments-attachinterface {
font-family: Helvetica, sans-serif;
font-size: 90%;
display: none;
position: fixed;
left: 0px;
top: 0px;
width: 100%;
height: 100%;
z-index: 2000;
background-image: url('../../images/st/popup/bg.png');
}
#st-attachments-manageinterface {
font-family: Helvetica, sans-serif;
font-size: 90%;
display: none;
position: absolute;
left: 0px;
top: 0px;
width: 100%;
height: 100%;
z-index: 2000;
background-image: url('../../images/st/popup/bg.png');
}
* html #st-attachments-attachinterface {
background-image: none;
}
* html #st-attachments-manageinterface {
background-image: none;
}
* html .popup-overlay {
background-image: url('../../images/st/popup/bg.png');
background-color: #000;
opacity: .70;
position: absolute;
left: 0px;
top: 0px;
width: 100%;
height: 100%;
z-index: 2001;
}
#st-attachments-attach-interface {
z-index: 2002;
background-color: #fff;
color: #000;
border: 4px solid #ccc;
padding: 1em;
width: 520px;
margin-left: auto;
margin-right: auto;
margin-top: 10%;
position: absolute;
top: 0px;
}
* html #st-attachments-attach-interface {
}
#st-attachments-attach-formtarget {
width: 0px;
height: 0px;
border: 0;
padding: 0;
margin: 0;
}
#st-attachments-attach-message {
font-size: 90%;
font-family: Verdana, Arial, Helvetica, Sans-Serif;
}
#st-attachments-attach-title {
font-weight: bold;
font-size: 120%;
}
#st-attachments-attach-close {
float: right;
margin-top: 6px;
}
#st-attachments-attach-uploadbutton {
float: right;
margin-right: 6px;
margin-top: 6px;
padding-bottom: 0;
}
#st-attachments-attach-fileprompt {
margin: 0.2em 0 0.4em 0;
padding-bottom: 0px;
}
#st-attachments-attach-submit {
font-size: 90%;
font-weight: bold;
}
#st-attachments-attach-filename {
font-size: 90%;
}
#st-attachments-attach-uploadmessage {
font-weight: bold;
margin-bottom: 1em;
display: none;
}
#st-attachments-attach-error {
font-weight: bold;
color: #f00;
margin-bottom: 1em;
display: none;
}
#st-attachments-attach-list {
display: none;
color: #666;
font-size: 90%;
margin-top: 1em;
margin-bottom: 1em;
border-top: 1px solid #4949BA;
border-bottom: 1px solid #4949BA;
background-color: #F5F5F5;
padding: 3px;
}
.st-attachments-attach-listlabel {
font-size: 90%;
color: #4949BA;
}
/* Queue File Dialog */
#st-attachmentsqueue-interface {
font-family: Helvetica, sans-serif;
font-size: 90%;
display: none;
position: fixed;
left: 0px;
top: 0px;
width: 100%;
height: 100%;
background-image: url('../../images/st/popup/bg.png'); /* Don't forget IE hack for ship! */
z-index: 2000;
}
* html #st-attachmentsqueue-interface {
background-image: none;
}
#st-attachmentsqueue-dialog {
z-index: 2002;
background-color: #fff;
color: #000;
border: 4px solid #ccc;
padding: 1em;
width: 530px;
margin-left: auto;
margin-right: auto;
margin-top: 10%;
position: absolute;
top: 0px;
}
* html #st-attachmentsqueue-dialog {
}
#st-attachmentsqueue-fileprompt {
margin-bottom: 0.4em;
margin-top: 0;
padding-bottom: 0;
}
#st-attachmentsqueue-title {
font-weight: bold;
font-size: 120%;
}
#st-attachmentsqueue-close {
float: right;
margin-top: 6px;
}
#st-attachmentsqueue-uploadbutton {
float: right;
margin-right: 6px;
margin-top: 6px;
padding-bottom: 0;
}
#st-attachmentsqueue-submit {
font-size: 90%;
}
#st-attachmentsqueue-filename {
font-size: 90%;
}
#st-attachmentsqueue-message {
font-size: 90%;
font-family: Verdana, Arial, Helvetica, Sans-Serif;
}
#st-attachmentsqueue-uploadmessage {
font-weight: bold;
margin-bottom: 1em;
display: none;
}
#st-attachmentsqueue-error {
font-weight: bold;
color: #f00;
margin-bottom: 1em;
display: none;
}
#st-attachmentsqueue-list {
display: none;
color: #666;
font-size: 90%;
margin-top: 1em;
margin-bottom: 1em;
border-top: 1px solid #4949BA;
border-bottom: 1px solid #4949BA;
background-color: #F5F5F5;
padding: 3px;
}
.st-attachmentsqueue-listlabel {
font-size: 90%;
color: #4949BA;
}
/* Lists */
tr.st-trbg-even, tr.st-trbg-even td{
background-color: #f3f7f7;
}
tr.w-st-even-row, tr.w-st-even-row td {
background-color: #f3f7f7;
}
.query-results-header-title, .query-results-header-last-edit-by {
text-align: left;
}
.query-results-row-revisions {
text-align: right;
}
.query-results-content {
font-size: 85%;
border-collapse: collapse;
border: 1px dashed #ddd;
border-left: 1px solid #ddd;
border-right: 1px solid #ddd;
}
.query-results-row {
border-collapse: collapse;
border: 1px dashed #ddd;
border-left: 1px solid #ddd;
border-right: 1px solid #ddd;
}
.query-results-row a {
text-decoration: underline;
color: #00f;
}
.query-results-row td {
font-family: Verdana;
padding: 0.3em;
border-left: 1px dashed #ddd;
border-right: 1px dashed #ddd;
border-top: 1px solid #ddd;
border-bottom: 1px solid #ddd;
}
.query-results-header-row {
border-collapse: collapse;
border: 1px dashed #ddd;
border-left: 1px solid #ddd;
border-right: 1px solid #ddd;
}
.query-results-header-row a {
text-decoration: underline;
color: #00f;
}
.query-results-header-row th {
font-family: Helvetica;
padding: 0.3em;
border-left: 1px dashed #ddd;
border-right: 1px dashed #ddd;
border-top: 1px solid #ddd;
border-bottom: 1px solid #ddd;
}
div.st-actionbutton {
float: left;
}
div#deleteme-st-actions-bar {
clear: both;
margin: 0.8em 20px 0.2em auto;
padding: 0;
}
/* Manage File Interface */
#st-attachments-manage-interface {
z-index: 2002;
background-color: #fff;
color: #000;
border: 4px solid #ccc;
padding: 1em;
width: 520px;
margin-left: auto;
margin-right: auto;
margin-top: 10%;
position: absolute;
top: 0px;
}
#st-attachments-manage-filetable {
height: 150px;
margin: 0;
padding: 0;
width: 100%;
overflow: auto;
border: 1px solid #ccc;
}
#st-attachments-manage-filelisting tbody td {
font-size: 90%;
}
#st-attachments-manage-filelisting {
width: 100%;
border-collapse: collapse;
border: 0;
margin: 0;
padding: 0;
}
#st-attachments-manage-fileheader {
background: #ccc;
font-weight: bold;
border-bottom: 1px black solid;
}
#st-attachments-manage-close {
float: right;
margin-top: 3px;
margin-right: -2px;
font-weight: bold;
}
#st-attachments-manage-delete {
margin-top: 3px;
float: left;
font-weight: bold;
}
.st-attachments-manage-filerow {
border-bottom: 1px solid #ccc;
}
.row-odd {
background-color: #eee;
}
.row-even {
background-color: #fff;
}
.row-on {
background-color: #009 !important;
color: white !important;
}
.row-on a {
color: #fff !important;
}
#st-attachments-manage-deletemessage {
color: red;
}
/* Page tools icons */
#st-pagetools-print {
background: url('../../images/st/pagetools/print.gif')
left center no-repeat;
}
#st-pagetools-email {
background: url('../../images/st/pagetools/email.gif')
left center no-repeat;
}
#st-pagetools-tools {
background: url('../../images/st/pagetools/tools.gif')
left center no-repeat;
}
/*
#st-pagetools-watch {
background: url('../../images/st/pagetools/watch-blue.gif')
left center no-repeat;
}
*/
/* *********** Settings *********** */
#st-settings-pane {
}
* html #settings-pane { font-size: 85%;}
.settings-start-table {
}
* html .settings-start-table { font-size: 90%;}
#st-settings-select {
padding: 0px 10px 10px 10px;
vertical-align: top;
width: 1px;
background-color: #eff1ec;
border: none;
}
#st-settings-section {
padding: 0px 10px 10px 10px;
vertical-align: top;
}
.settings-top-header {
margin-top: 1em;
font-weight: bold;
width: 15em;
}
.settings-header {
margin-top: 1em;
font-weight: bold;
}
.settings-selections {
padding: 0px 0px 0px 20px;
line-height: 1.5em;
}
.settings-selections a:visited, .settings-selections a:active {
color: #0000ff;
}
.settings-link {
clear: both;
display: block;
}
.settings-section-left {
text-align: right;
}
.settings-label {
font-weight: bold;
}
.settings-help {
color: #888;
}
.settings-comment {
}
.users-invite-message {
padding: 0.5em 0.5em 0.5em 2em;
background-color: #eee;
/* This seems necessary to fix an IE bug that sometimes
causes the text in this div to be invisible */
z-index: 1000;
}
.workspace-entry-header {
margin-top: .5em;
font-weight: bold;
}
.workspace-entry {
margin-left: 3em;
}
.workspace-entry-p {
margin-top: .5em;
margin-bottom: .75em;
}
.workspace-subentry {
font-style: italic;
font-weight: bold;
margin-left: 1.5em;
}
.preferences-td {
padding:.5em 0 1.5em 0;
}
.preferences-query {
text-align: left;
}
.preference-radio {
background-color: #cec;
}
.user-settings-listall-headings td {
background-color: #eff3ef;
}
#st-settings-save {
padding-bottom: 0.5em;
}
.standard-button-cancel {
font-weight: bold;
background-color: #71004b;
border-left: 1px solid #aaa;
border-top: 1px solid #aaa;
border-bottom: 2px solid #333;
border-right: 2px solid #333;
color: #f4f3b9;
width: 8em;
}
.standard-button-submit {
font-weight: bold;
background-color: #656084;
border-left: 1px solid #aaa;
border-top: 1px solid #aaa;
border-bottom: 2px solid #333;
border-right: 2px solid #333;
color: #f4f3b9;
width: 8em;
}
#st-settings {
font-family: Verdana, Arial, Helvetica, Sans-Serif;
font-size: 90%;
}
/* Listview Tabs */
#st-listview a:visited {
color: #551a8b;
}
#st-listview-tabs ul {
display: block;
list-style: none outside;
margin: 0 0 0 4em;
padding: 0;
font-family: Helvetica, Arial, Sans-serif;
font-size: 80%;
}
#st-listview-tabs li {
display: block;
float: left;
margin: 0 0.8em 0 0;
padding: 3px 0.6em 0 0.6em;
border: 1px solid #d8d8d8;
border-bottom: 1px solid rgb(128, 169, 243);
background-color: #f4f4f4;
position: relative;
bottom: -2px;
}
#st-listview-tabs li.spacer {
margin: 0 0.8em 0 2em;
}
#st-listview-tabs a {
color: #bbb;
text-decoration: none;
}
#st-listview-tabs li.selected {
background-color: #fff !important;
border: 1px solid rgb(128, 169, 243) !important;
border-bottom: 1px solid #fff !important;
font-weight: bold !important;
}
#st-listview-tabs li.selected a {
color: #000 !important;
}
/* Category List Display */
#st-category-display-links {
margin-bottom: 1em;
font-size: 90%;
}
#st-tag-listbody {
font-family: Helvetica, Verdana, sans-serif;
}
/* Attachments List Display */
#st-attachments-list-body table.button-table {
margin-top: 0.1em;
font-size: 80%;
}
/* ********** PageTools Menu ************** */
div#st-editing-tools {
float: left;
}
div#st-pagetools {
z-index: 300;
font-family: Helvetica, Verdana, sans-serif;
font-size: 10px;
float: right;
margin: 18px 0 0 0em;
color: #000;
vertical-align: bottom;
position: relative;
}
#st-pagetools a {
text-decoration: none;
color: black;
padding-left: 17px;
}
#st-pagetools span {
color: inherit;
padding-left: 17px;
vertical-align: top;
}
#st-pagetools span.st-watchlist-link {
color: inherit;
vertical-align: top;
}
.st-watchlist-link {
cursor: pointer;
}
div#st-pagetools ul.level2 {
z-index: 300;
margin: 0;
padding: 0;
background: white;
border: 1px solid #CCC;
border-width: 0 1px;
}
div#st-pagetools li {
position: relative;
list-style: none;
margin: 0;
float: left;
width: 7em;
line-height: 11px;
}
div#st-pagetools ul ul li:hover {
background: #BFE2FF;
}
div#st-pagetools li a {
display: block;
text-decoration: none;
}
div#st-pagetools>ul a {
width: auto;
}
div#st-pagetools ul ul {
position: absolute;
width: auto;
display: none;
}
div#st-pagetools ul ul li {
line-height: 1.5em;
/* width: 100%; */
width: 14em;
}
.first {
border-top: 1px solid #CCC;
}
.separator {
border-bottom: 1px solid #CCC;
}
div#st-pagetools ul ul li a {
border-bottom: 1px solid #CCC;
padding-left: 15px;
padding-right: 3px;
margin-right: 3px;
border: 0px;
}
div#st-pagetools li.submenu li.submenu:hover {
z-index: 300;
background-color: #BFE2FF;
}
div#st-pagetools ul.level1 li.submenu:hover ul.level2 {
display:block;
}
div#st-pagetools ul.level2 {
top: 1.0em;
left: -9.5em;
}
/*
=head2 Revision List Display
Change these styles to update the page revision list.
*/
#st-revision-list-table {
border-collapse: collapse;
font-size: 85%;
color: #000;
}
.st-page-title-decorator {
color: #C80000;
}
.st-revision-header-emphasis {
color: #C80000;
}
.st-revision-list-compare-button-row {
}
.st-revision-list-compare-button-cell {
padding-top: 0.3em;
text-align: center;
}
.st-revision-list-compare-button {
}
#st-revision-list-header-row {
}
#st-revision-list-header-select {
padding: 6px 2px 2px 2px;
text-align: center;
}
#st-revision-list-header-revision {
padding: 6px 2px 2px 2px;
text-align: left;
}
#st-revision-list-header-edited-by {
padding: 6px 2px 2px 2px;
text-align: center;
}
#st-revision-list-header-date {
padding: 6px 2px 2px 2px;
text-align: center;
}
.st-revision-list-row {
border-collapse: collapse;
border: 1px dashed #ddd;
border-left: 1px solid #ddd;
border-right: 1px solid #ddd;
}
.st-revision-list-row td {
font-family: Verdana;
padding: 0.3em;
border-left: 1px dashed #ddd;
border-right: 1px dashed #ddd;
border-top: 1px solid #ddd;
border-bottom: 1px solid #ddd;
}
.st-revision-list-row-select {
padding: 3px 0 2px 0;
text-align: center;
}
.st-revision-list-row-select-old {
}
.st-revision-list-row-select-new {
}
.st-revision-list-row-revision {
}
.st-revision-list-row-revision-link {
}
.st-revision-list-row-edited-by {
}
.st-revision-list-row-date {
}
/* Revision Menu */
#st-pagetools.st-revision-view-bar {
float: left;
}
ul.st-revision-menu {
list-style: none;
margin: 0;
padding: 0.2em;
font-size: 80%;
}
ul.st-revision-menu li {
float: left;
padding: 0 0.4em 0 0.4em;
border-right: thin solid #000000;
}
ul.st-revision-menu li.st-last {
border-right: none;
}
#st-restore-revision-button {
font-size: 80%;
}
/*
=head2 Revision Compare Display
When comparing two revisions of a page, these styles apply.
*/
#st-revision-compare-table {
background-color: #f0f0f0;
}
#st-revision-compare-table td {
background-color: white;
}
.st-revision-compare-old {
background-color: #fdd;
text-decoration: line-through;
}
.st-revision-compare-new {
background-color: #dfd;
font-weight: bold;
}
/* Weblog View */
#st-weblog {
padding: 0;
}
#st-content-weblog-display-width-controller {
}
#st-content-weblog-display-width-controller-nav {
width: 230px;
margin-left: 15px;
border-left: 5px solid #ddd;
margin-top: -1px;
}
#st-weblog-content {
font-family: Verdana, Helvetica, sans-serif;
margin-top: -1px;
margin-bottom: -1px;
border-top: 1px solid #80a9f3;
border-bottom: 1px solid #80a9f3;
}
#st-weblog-title {
font-family: 'Trebuchet MS', Verdana, Helvetica, sans-serif;
font-family: 'Times New Roman', serif;
background-color: #80a9f3;
color: #fff;
font-size: 150%;
font-weight: bold;
padding: 0.2em;
padding-left: 1em;
}
#st-weblog-wikititle {
font-family: Helvetica, Verdana, sans-serif;
font-style: italic;
font-size: 40%;
color: #fff;
margin-bottom: 0.2em;
margin-top: 0.1em;
padding-top: 0;
}
#st-weblog-titletext {
font-family: Helvetica, Verdana, sans-serif;
font-weight: bold;
color: #fff;
}
div.st-weblog-entry {
margin-top: 0.2em;
margin-bottom: 4.8em;
padding: 0 1.5em 0 1.5em;
}
.st-page-title {
clear: both;
}
div.st-weblog-entrytitle span.text {
font-family: Helvetica, Verdana, sans-serif;
font-size: 150%;
font-weight: bold;
color: #000;
}
.st-weblog-entrycontent {
font-family: Verdana, Helvetica, sans-serif;
font-size: 90%;
border-bottom: 1px solid #888;
}
.st-weblog-byline {
float: left;
text-align: left;
font-style: italic;
font-size: 70%;
font-family: Verdana, Helvetica, sans-serif;
}
.st-weblog-post-links {
float: right;
text-align: right;
font-size: 70%;
font-family: Verdana, Helvetica, sans-serif;
}
#st-weblog-archives, #st-weblog-navigation {
position: relative;
float: right;
width: 230px;
}
#st-weblog-archives {
margin-top: 15px;
clear: right;
}
#st-weblog-archives-title, #st-weblog-navigation-title {
margin-left: 15px;
font-family: Helvetica, sans-serif;
font-size: 95%;
font-weight: bold;
color: #999;
border-bottom: 2px solid #f99;
padding-bottom: 5px;
padding-top: 5px;
margin-bottom: 5px;
}
#st-weblog-navigation-content {
margin-left: 15px;
font-size: 80%;
}
#st-weblog-archives ul {
margin: 0;
padding: 0;
}
#st-weblog-archives ul li {
/* list-type: none; */
display: block;
font-size: 80%;
font-family: Helvetica, sans-serif;
padding-left: 15px;
}
#st-weblog-newpost {
padding: 0.5em 0.7em 0.3em 0.3em;
}
#st-weblog-newpost-button {
}
#st-weblog-actionbar-chooseweblog {
float: right;
}
#st-weblog-postbyemail {
font-size: 70%;
font-family: Verdana, Helvetica, sans-serif;
color: #def;
padding-top: 0.4em;
}
#st-weblog-postbyemail-link {
color: #00c;
}
.st-weblog-chooseprompt {
font-size: 90%;
font-family: Verdana, Helvetica, sans-serif;
padding-right: 0.2em;
color: #000;
}
.st-spacer {
padding-right: 0.1em;
padding-left: 0.1em;
}
.st-weblog-preventries {
padding-bottom: 20px;
clear: both;
}
.st-weblog-nextentries {
clear: both;
}
div.st-weblog-entrynav {
margin-top: 0.2em;
margin-bottom: 1.8em;
padding: 0;
}
span.st-weblog-previousentries, span.st-weblog-nextentries {
font-size: 90%;
font-family: Verdana, Helvetica, sans-serif;
padding-left: 1em;
}
/* ******* Page Stats ******** */
#st-usagereport-navbar {
font-size: 80%;
padding: 0;
margin: 0;
}
#st-usagereport-date {
font-weight: bold;
margin-top: 1em;
}
#st-page-usagereport h1 {
font-size: 1.3em;
font-weight: bold;
margin-top: 1.2em;
margin-bottom: 0.3em;
}
#st-page-usagereport h2 {
font-size: 1.1em;
font-weight: bold;
margin-top: 0.8em;
margin-bottom: 0.3em;
}
/* New Page */
#st-newpage-save, #st-newpage-duplicate {
display: none;
position: fixed;
left: 0px;
top: 0px;
width: 100%;
height: 100%;
background: url('../../images/st/popup/bg.png'); /* Don't forget IE hack for ship! */
z-index: 2000;
}
#st-newpage-save-interface {
background-color: #fff;
color: #000;
border: 4px solid #ccc;
padding: 0.5em;
width: 450px;
margin-left: auto;
margin-right: auto;
margin-top: 10%;
position:absolute;
top:0px;
z-index:2003;
}
#st-newpage-duplicate-interface {
background-color: #fff;
color: #000;
border: 4px solid #ccc;
padding: 0.5em;
width: 530px;
margin-left: auto;
margin-right: auto;
margin-top: 10%;
position:absolute;
top:0px;
z-index:2003;
}
#st-newpage-save-title, #st-newpage-duplicate-title {
margin: 0;
padding: 0;
font-weight: bold;
font-family: Helvetica, sans-serif;
font-size: 100%;
}
#st-newpage-save-prompt, #st-newpage-duplicate-prompt {
font-family: Helvetica, sans-serif;
font-size: 90%;
margin-bottom: 0.4em;
}
#st-newpage-save-buttons, #st-newpage-duplicate-buttons {
margin-top: 0.8em;
text-align: right;
}
.st-newpage-duplicate-option {
font-family: Helvetica, sans-serif;
font-size: 90%;
margin: 0;
padding: 0;
}
#st-newpage-duplicate-pagename {
font-size: 90%;
}
.st-newpage-duplicate-emphasis {
background-color: #FFFF00;
font-weight: bold;
}
#st-newpage-save-field-pagename {
margin-bottom: 0;
margin-top: 0.2em;
padding-bottom: 0;
font-size: 90%;
}
#st-newpage-save-tip {
margin-bottom: 0;
margin-top: 1.2em;
padding-bottom: 0;
font-size: 75%;
color: #888;
}
/* Wikitext Styling */
.wiki {
}
.wiki hr {
margin-top: .4em;
margin-bottom: .4em;
}
.wiki .short-rule {
width: 25%;
}
.wiki .medium-rule {
width: 50%
}
.wiki ul,
.wiki ol,
.wiki blockquote {
margin-left: 2em;
padding-left: 0em;
}
.wiki table {
border-collapse: collapse;
}
.wiki td {
border: 1px;
border-style: solid;
padding: .2em;
vertical-align: top;
}
.wiki h1,
.wiki h2,
.wiki h3,
.wiki h4,
.wiki h5,
.wiki h6 {
font-weight: bold;
font-style: normal;
margin-top: 0.1em;
margin-bottom: 8px;
}
.wiki h1 {font-size: 200%;}
.wiki h2 {font-size: 170%;}
.wiki h3 {font-size: 145%;}
.wiki h4 {font-size: 125%;}
.wiki h5 {font-size: 110%;}
.wiki h6 {font-size: 100%;}
.wiki pre {
background-color: #eee; /* XXX */
margin-left: 1em;
margin-right: 1em;
padding: .2em;
}
.wiki .incipient {
text-decoration: none;
border-bottom: 1px dashed;
}
.wiki-include-title {
background-color: #ccccff;
}
.wiki .wiki {
position: relative;
background-color: #ddddff;
border: 1px solid #ccccff;
padding: 3px;
}
.wafl_existence_error {
color: rgb(200,0,0);
border-bottom: 0.2em dashed rgb(200,0,0);
}
#st-edit-mode-container {
}
#st-edit-mode-view {
}
#st-page-editing-uploadbutton {
z-index: 1500;
float: left;
}
/* Comment UI */
body#st-commentui {
background: #ffffff;
}
#st-commentui-container {
}
#st-commentui-container a:visited,
#st-commentui-container a:active {
color: #00f;
}
#st-commentui-notetop {
}
#st-commentui-controls {
}
#st-commentui-savelink {
background-color: #fffebd;
}
#st-commentui-cancellink {
}
#st-commentui-customfield {
}
#st-commentui-customfield .customfield-label {
}
#st-commentui-customfield .customfield-input {
}
#st-commentui-textarea {
padding: 0;
border-style: inset;
border-width: thin;
background-color: #ffd;
color: black;
width: 99%;
height: 150px;
}
/*
=head2 Send Page by Email
Styles for the 'Send Page by Email' popup, accessed from the 'Email' dropdown
menu on the page bar.
*/
#email-page {
background: #ffffff;
font-size: 80%;
}
.email-page-row {
clear: both;
}
.email-page-row-label {
font-weight: bold;
float: left;
width: 5em;
margin-left: 1.2em;
margin-right: 1.2em;
text-align: right;
}
.email-page-row-content {
float: left;
padding-bottom: 1.2em;
}
.email-page-user-select-column {
float: left;
padding-right: 1.2em;
width: 14em;
}
#email-page-user-select-column-center {
width: 10em;
}
.email-page-user-select-label {
text-align: center;
}
#email-page-user-select-add-label {
padding-top: 1em;
}
.email-page-user-select-button-group {
padding-bottom: 2em;
}
.email-page-input {
width: 120px;
clear: both;
display: block;
}
.email-page-select {
width: 175px;
font-size: x-small;
}
#email-page-error-message {
text-align: center;
}
#email-page-buttons-container {
clear: both;
}
#email-page-buttons {
text-align: center;
}
.email-page-input-new {
width: 175px;
}
/* System Status, Red with icon */
#st-system-status-alert {
clear: both;
width: 50%;
margin-left: 25%;
margin-top: 10px;
padding: 5px;
color: #c00;
font-weight: bold;
font-size: 80%;
background: transparent url('../../images/st/system-message/important-note.gif') no-repeat 5px center;
padding-left: 60px;
min-height: 38px;
}
* html #st-system-status-alert {
height: 38px;
}
/* System Status, Green */
#st-system-status {
clear: both;
text-align:center;
width: 80%;
margin-left: 10%;
padding: 8px 0 3px 0;
color: #0a0;
font-family: Arial, Helvetica, sans-serif;
font-size: 80%;
}
.socialtextLogo {
text-align: center;
}
/*}}}*/
/***
|''Name:''|SparklinePlugin|
|''Description:''|Sparklines macro|
***/
//{{{
if(!version.extensions.SparklinePlugin) {
version.extensions.SparklinePlugin = {installed:true};
//--
//-- Sparklines
//--
config.macros.sparkline = {};
config.macros.sparkline.handler = function(place,macroName,params)
{
var data = [];
var min = 0;
var max = 0;
var v;
for(var t=0; t<params.length; t++) {
v = parseInt(params[t]);
if(v < min)
min = v;
if(v > max)
max = v;
data.push(v);
}
if(data.length < 1)
return;
var box = createTiddlyElement(place,"span",null,"sparkline",String.fromCharCode(160));
box.title = data.join(",");
var w = box.offsetWidth;
var h = box.offsetHeight;
box.style.paddingRight = (data.length * 2 - w) + "px";
box.style.position = "relative";
for(var d=0; d<data.length; d++) {
var tick = document.createElement("img");
tick.border = 0;
tick.className = "sparktick";
tick.style.position = "absolute";
tick.src = "data:image/gif,GIF89a%01%00%01%00%91%FF%00%FF%FF%FF%00%00%00%C0%C0%C0%00%00%00!%F9%04%01%00%00%02%00%2C%00%00%00%00%01%00%01%00%40%02%02T%01%00%3B";
tick.style.left = d*2 + "px";
tick.style.width = "2px";
v = Math.floor(((data[d] - min)/(max-min)) * h);
tick.style.top = (h-v) + "px";
tick.style.height = v + "px";
box.appendChild(tick);
}
};
}
//}}}
/***
|''Name:''|CryptoFunctionsPlugin|
|''Description:''|Support for cryptographic functions|
***/
//{{{
if(!version.extensions.CryptoFunctionsPlugin) {
version.extensions.CryptoFunctionsPlugin = {installed:true};
//--
//-- Crypto functions and associated conversion routines
//--
// Crypto "namespace"
function Crypto() {}
// Convert a string to an array of big-endian 32-bit words
Crypto.strToBe32s = function(str)
{
var be = Array();
var len = Math.floor(str.length/4);
var i, j;
for(i=0, j=0; i<len; i++, j+=4) {
be[i] = ((str.charCodeAt(j)&0xff) << 24)|((str.charCodeAt(j+1)&0xff) << 16)|((str.charCodeAt(j+2)&0xff) << 8)|(str.charCodeAt(j+3)&0xff);
}
while (j<str.length) {
be[j>>2] |= (str.charCodeAt(j)&0xff)<<(24-(j*8)%32);
j++;
}
return be;
};
// Convert an array of big-endian 32-bit words to a string
Crypto.be32sToStr = function(be)
{
var str = "";
for(var i=0;i<be.length*32;i+=8)
str += String.fromCharCode((be[i>>5]>>>(24-i%32)) & 0xff);
return str;
};
// Convert an array of big-endian 32-bit words to a hex string
Crypto.be32sToHex = function(be)
{
var hex = "0123456789ABCDEF";
var str = "";
for(var i=0;i<be.length*4;i++)
str += hex.charAt((be[i>>2]>>((3-i%4)*8+4))&0xF) + hex.charAt((be[i>>2]>>((3-i%4)*8))&0xF);
return str;
};
// Return, in hex, the SHA-1 hash of a string
Crypto.hexSha1Str = function(str)
{
return Crypto.be32sToHex(Crypto.sha1Str(str));
};
// Return the SHA-1 hash of a string
Crypto.sha1Str = function(str)
{
return Crypto.sha1(Crypto.strToBe32s(str),str.length);
};
// Calculate the SHA-1 hash of an array of blen bytes of big-endian 32-bit words
Crypto.sha1 = function(x,blen)
{
// Add 32-bit integers, wrapping at 32 bits
add32 = function(a,b)
{
var lsw = (a&0xFFFF)+(b&0xFFFF);
var msw = (a>>16)+(b>>16)+(lsw>>16);
return (msw<<16)|(lsw&0xFFFF);
};
// Add five 32-bit integers, wrapping at 32 bits
add32x5 = function(a,b,c,d,e)
{
var lsw = (a&0xFFFF)+(b&0xFFFF)+(c&0xFFFF)+(d&0xFFFF)+(e&0xFFFF);
var msw = (a>>16)+(b>>16)+(c>>16)+(d>>16)+(e>>16)+(lsw>>16);
return (msw<<16)|(lsw&0xFFFF);
};
// Bitwise rotate left a 32-bit integer by 1 bit
rol32 = function(n)
{
return (n>>>31)|(n<<1);
};
var len = blen*8;
// Append padding so length in bits is 448 mod 512
x[len>>5] |= 0x80 << (24-len%32);
// Append length
x[((len+64>>9)<<4)+15] = len;
var w = Array(80);
var k1 = 0x5A827999;
var k2 = 0x6ED9EBA1;
var k3 = 0x8F1BBCDC;
var k4 = 0xCA62C1D6;
var h0 = 0x67452301;
var h1 = 0xEFCDAB89;
var h2 = 0x98BADCFE;
var h3 = 0x10325476;
var h4 = 0xC3D2E1F0;
for(var i=0;i<x.length;i+=16) {
var j,t;
var a = h0;
var b = h1;
var c = h2;
var d = h3;
var e = h4;
for(j = 0;j<16;j++) {
w[j] = x[i+j];
t = add32x5(e,(a>>>27)|(a<<5),d^(b&(c^d)),w[j],k1);
e=d; d=c; c=(b>>>2)|(b<<30); b=a; a = t;
}
for(j=16;j<20;j++) {
w[j] = rol32(w[j-3]^w[j-8]^w[j-14]^w[j-16]);
t = add32x5(e,(a>>>27)|(a<<5),d^(b&(c^d)),w[j],k1);
e=d; d=c; c=(b>>>2)|(b<<30); b=a; a = t;
}
for(j=20;j<40;j++) {
w[j] = rol32(w[j-3]^w[j-8]^w[j-14]^w[j-16]);
t = add32x5(e,(a>>>27)|(a<<5),b^c^d,w[j],k2);
e=d; d=c; c=(b>>>2)|(b<<30); b=a; a = t;
}
for(j=40;j<60;j++) {
w[j] = rol32(w[j-3]^w[j-8]^w[j-14]^w[j-16]);
t = add32x5(e,(a>>>27)|(a<<5),(b&c)|(d&(b|c)),w[j],k3);
e=d; d=c; c=(b>>>2)|(b<<30); b=a; a = t;
}
for(j=60;j<80;j++) {
w[j] = rol32(w[j-3]^w[j-8]^w[j-14]^w[j-16]);
t = add32x5(e,(a>>>27)|(a<<5),b^c^d,w[j],k4);
e=d; d=c; c=(b>>>2)|(b<<30); b=a; a = t;
}
h0 = add32(h0,a);
h1 = add32(h1,b);
h2 = add32(h2,c);
h3 = add32(h3,d);
h4 = add32(h4,e);
}
return Array(h0,h1,h2,h3,h4);
};
}
//}}}
/***
|''Name:''|DeprecatedFunctionsPlugin|
|''Description:''|Support for deprecated functions removed from core|
***/
//{{{
if(!version.extensions.DeprecatedFunctionsPlugin) {
version.extensions.DeprecatedFunctionsPlugin = {installed:true};
//--
//-- Deprecated code
//--
// @Deprecated: Use createElementAndWikify and this.termRegExp instead
config.formatterHelpers.charFormatHelper = function(w)
{
w.subWikify(createTiddlyElement(w.output,this.element),this.terminator);
};
// @Deprecated: Use enclosedTextHelper and this.lookaheadRegExp instead
config.formatterHelpers.monospacedByLineHelper = function(w)
{
var lookaheadRegExp = new RegExp(this.lookahead,"mg");
lookaheadRegExp.lastIndex = w.matchStart;
var lookaheadMatch = lookaheadRegExp.exec(w.source);
if(lookaheadMatch && lookaheadMatch.index == w.matchStart) {
var text = lookaheadMatch[1];
if(config.browser.isIE)
text = text.replace(/\n/g,"\r");
createTiddlyElement(w.output,"pre",null,null,text);
w.nextMatch = lookaheadRegExp.lastIndex;
}
};
// @Deprecated: Use <br> or <br /> instead of <<br>>
config.macros.br = {};
config.macros.br.handler = function(place)
{
createTiddlyElement(place,"br");
};
// Find an entry in an array. Returns the array index or null
// @Deprecated: Use indexOf instead
Array.prototype.find = function(item)
{
var i = this.indexOf(item);
return i == -1 ? null : i;
};
// Load a tiddler from an HTML DIV. The caller should make sure to later call Tiddler.changed()
// @Deprecated: Use store.getLoader().internalizeTiddler instead
Tiddler.prototype.loadFromDiv = function(divRef,title)
{
return store.getLoader().internalizeTiddler(store,this,title,divRef);
};
// Format the text for storage in an HTML DIV
// @Deprecated Use store.getSaver().externalizeTiddler instead.
Tiddler.prototype.saveToDiv = function()
{
return store.getSaver().externalizeTiddler(store,this);
};
// @Deprecated: Use store.allTiddlersAsHtml() instead
function allTiddlersAsHtml()
{
return store.allTiddlersAsHtml();
}
// @Deprecated: Use refreshPageTemplate instead
function applyPageTemplate(title)
{
refreshPageTemplate(title);
}
// @Deprecated: Use story.displayTiddlers instead
function displayTiddlers(srcElement,titles,template,unused1,unused2,animate,unused3)
{
story.displayTiddlers(srcElement,titles,template,animate);
}
// @Deprecated: Use story.displayTiddler instead
function displayTiddler(srcElement,title,template,unused1,unused2,animate,unused3)
{
story.displayTiddler(srcElement,title,template,animate);
}
// @Deprecated: Use functions on right hand side directly instead
var createTiddlerPopup = Popup.create;
var scrollToTiddlerPopup = Popup.show;
var hideTiddlerPopup = Popup.remove;
// @Deprecated: Use right hand side directly instead
var regexpBackSlashEn = new RegExp("\\\\n","mg");
var regexpBackSlash = new RegExp("\\\\","mg");
var regexpBackSlashEss = new RegExp("\\\\s","mg");
var regexpNewLine = new RegExp("\n","mg");
var regexpCarriageReturn = new RegExp("\r","mg");
}
//}}}
This is the home page for Dobrica Pavlinušić's random unstructured stuff.
Welcome to my new unsorted stuff site. If you are here to "learn about rot13"<http://en.wikipedia.org/wiki/ROT13> this might not be the right place.
If you are, however looking latest and/or unsorted snippets which didn't made to "my homepage"<http://www.rot13.org/~dpavlin/> or "blog"<http://blog.rot13.org/> you might be on right place.
| {search: category: projects} | {search: category: howto} | {recent_changes: rot13} |
{fetchrss: http://blog.rot13.org/index.xml}
Fun with OpenOffice. Non-interactive fun, that is :-)
^ install
.pre
sudo apt-get install openoffice.org-dev
.pre
^ OpenOffice::UNO
.pre
cd ~/.cpanplus/5.10.0/build/OpenOffice-UNO-0.06
. /usr/lib/openoffice/basis3.1/sdk/setsdkenv_unix.sh
perl Makefile.PL
make
ooffice "-accept=socket,host=localhost,port=8100;urp;StarOffice.ServiceManager"
# -nologo -headless -nofirststartwizard
.pre
{toc: }
This page documents my attempt to install Seaside as loadbalanced configuration with multiple squeak images under OpenVZ
^ Create VE
.pre
# download template
root@mljac:~# cd /var/lib/vz/template/cache
root@mljac:~# wget http://download.openvz.org/template/precreated/contrib/debian-5.0-i386-minimal.tar.gz
root@mljac:~# vzctl create 1001 --ostemplate debian-5.0-i386-minimal --ipadd 10.0.0.1 --hostname gw.rot13.org
# configure
root@mljac:~# vzctl set 1011 --nameserver 192.168.1.2 --save
.pre
Use something like {file: vz-nat.sh} to configure NAT on your OpenVZ machine.
^ Seaside
.pre
# dependencies
root@seaside:/srv# apt-get install unzip
root@seaside:/srv# wget -nd -nH http://www.seaside.st/distributions/Seaside-2.8.3.app.zip
root@seaside:/srv# unzip Seaside-2.8.3.app.zip
Archive: Seaside-2.8.3.app.zip
root@seaside:/srv# ln -s Seaside-2.8-578.app seaside
Adding new group `squeak' (1000) ...
Adding new user `squeak' (1000) with group `squeak' ...
Not creating home directory `/home/squeak'.
root@seaside:/srv# chown -R squeak:squeak Seaside-2.8-578.app/
.pre
^^ Startup
{file: Seaside.sh} - use something like this script to start headless squeak.
Actual `-headless` option didn't seem to work for me
^ Front-end HTTP proxy
{include: [nginx]}
^ Monitoring
We will be using "monit"<http://mmonit.com/monit/>, light-weight process monitor written in C to monitor servers on our virtual machine. It will do startup of our services, monitor load and report alerts.
For it to work, we need to have a script which will start/stop squeak.
Use following configuration: {file: monitrc}
Also install following two shells scripts in `/srv' so that monit can call them to start or stop services
* {file: seaside.sh}
* {file: nginx.sh}
.pre
# check syntax
root@seaside:~# /etc/init.d/monit syntax
Control file syntax OK
.pre
And you are rady to go.
* "monit@squeak1"<http://seaside.rot13.org:2812/> to view current server status
^^ Test
open "http://hostname:8080/seaside/"<http://seaside.rot13.org:8080/seaside/> to test seaside
^ More info
* http://onsmalltalk.com/scaling-seaside-more-advanced-load-balancing-and-publishing
* http://blog.blobworks.com/2008/12/16/squeak-in-jail/
* https://bytesmith.seework.com
.pre
{weblog_list: }
.pre
{toc: }
^ first steps
Here I will try to document correct order to read documentation to get setup for ULX3S:
https://github.com/emard/ulx3s-bin/blob/master/README.md
There is also useful things from chat at [ULX3S Lobby]
^^ udev rule
^^ ujprog
.pre
git clone https://github.com/f32c/tools f32c-tools
cd f32c-tools/ujprog/
dpavlin@x200:/mnt/nuc/FPGA/f32c-tools/ujprog$ rm ujprog
dpavlin@x200:/mnt/nuc/FPGA/f32c-tools/ujprog$ make -f Makefile.linux
cc -Wall -D__linux__ -std=gnu99 -static ujprog.c /usr/lib/x86_64-linux-gnu/libftdi.a /usr/lib/x86_64-linux-gnu/libusb.a -o ujprog
dpavlin@x200:/mnt/nuc/FPGA/f32c-tools/ujprog$ sudo cp ujprog /usr/local/bin/
.pre
* create udev rule
^^ passthru to access esp32
source at https://github.com/emard/ulx3s-passthru
.pre
dpavlin@x200:/mnt/nuc/FPGA/ulx3s-bin/fpga/passthru/passthru-v20-85f$ ujprog -j flash ulx3s_85f_passthru.bit
ULX2S / ULX3S JTAG programmer v 3.0.92 (built Nov 19 2019 10:55:50)
Using USB cable: ULX3S FPGA 12K v3.0.3
[Wed Nov 20 18:02:01 2019] ftdi_sio ttyUSB0: FTDI USB Serial Device converter now disconnected from ttyUSB0
[Wed Nov 20 18:02:01 2019] ftdi_sio 1-5.2:1.0: device disconnected
Programming: 100%
Completed in 24.36 seconds.
[Wed Nov 20 18:02:25 2019] usb 1-5.2: reset full-speed USB device number 56 using ehci-pci
[Wed Nov 20 18:02:26 2019] ftdi_sio 1-5.2:1.0: FTDI USB Serial Device converter detected
[Wed Nov 20 18:02:26 2019] usb 1-5.2: Detected FT-X
[Wed Nov 20 18:02:26 2019] usb 1-5.2: FTDI USB Serial Device converter now attached to ttyUSB0
.pre
^^ update size of your FPGA
.pre
dpavlin@x200:/mnt/nuc/FPGA/ulx3s-bin$ usb-jtag/linux-amd64/ftx_prog --product "ULX3S FPGA 85K v3.0.3"
.pre
power cycle board to get new usb id, test that it's supported by ujprog
.pre
dpavlin@x200:/mnt/nuc/FPGA/ulx3s-bin$ ujprog -r
.pre
^^ esptool and esp32 booting problems
You should be using ecptool from ulx3s-bin repository to quite @emard from https://gitter.im/ulx3s/Lobby#dark-theme
> OK then. If you have issues with ESP32 not booting with SD card but booting without SD card then then the fuse burn script from ulx3s-bin should be run. So far so good, you erased its flash, try linux. If no issue then can try to flash micropython and my new ESP32 OTA programmer ecp5.py end uftpd.py
> I have wisely taken some esptool.py which works and frozen it in ulx3s, versions change all the time and maybe you took something in the middle of development action :)
^^ install micropython
https://github.com/emard/esp32ecp5/
.pre
dpavlin@nuc:/nuc/FPGA$ git clone https://github.com/emard/esp32ecp5/
dpavlin@nuc:/nuc/FPGA$ cd esp32ecp5/
dpavlin@x200:/mnt/nuc/FPGA/esp32ecp5$ wget https://micropython.org/resources/firmware/esp32-idf3-20191120-v1.11-580-g973f68780.bin
.pre
It's important to erase flash or micropyhton will complain about corrupt fat filesystem like:
FAT filesystem appears to be corrupted. If you had important data there, you
may want to make a flash snapshot to try to recover it. Otherwise, perform
factory reprogramming of MicroPython firmware (completely erase flash, followed
by firmware programming).
.pre
dpavlin@x200:/mnt/nuc/FPGA/esp32ecp5$ ../ulx3s-bin/esp32/serial-uploader/esptool.py --chip esp32 --port /dev/ttyUSB0 erase_flash
esptool.py v2.6-beta1
Serial port /dev/ttyUSB0
Connecting....
Chip is ESP32D0WDQ6 (revision 1)
Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None
MAC: a4:cf:12:55:c5:60
Uploading stub...
Running stub...
Stub running...
Erasing flash (this may take a while)...
Chip erase completed successfully in 8.7s
Hard resetting via RTS pin...
dpavlin@x200:/mnt/nuc/FPGA/esp32ecp5$ ../ulx3s-bin/esp32/serial-uploader/esptool.py --chip esp32 --port /dev/ttyUSB0 --baud 460800 write_flash -z 0x1000 esp32-idf3-20191120-v1.11-580-g973f68780.bin
esptool.py v2.6-beta1
Serial port /dev/ttyUSB0
Connecting....
Chip is ESP32D0WDQ6 (revision 1)
Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None
MAC: a4:cf:12:55:c5:60
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 460800
Changed.
Configuring flash size...
Auto-detected Flash size: 4MB
Compressed 1240192 bytes to 783187...
Wrote 1240192 bytes (783187 compressed) at 0x00001000 in 18.7 seconds (effective 529.3 kbit/s)...
Hash of data verified.
Leaving...
Hard resetting via RTS pin...
dpavlin@x200:/mnt/nuc/FPGA/esp32ecp5$ microcom -p /dev/ttyUSB0
connected to /dev/ttyUSB0
Escape character: Ctrl-\
Type the escape character to get to the prompt.
>>>
> help()
Welcome to MicroPython on the ESP32!
For generic online docs please visit http://docs.micropython.org/
For access to the hardware use the 'machine' module:
import machine
pin12 = machine.Pin(12, machine.Pin.OUT)
pin12.value(1)
pin13 = machine.Pin(13, machine.Pin.IN, machine.Pin.PULL_UP)
print(pin13.value())
i2c = machine.I2C(scl=machine.Pin(21), sda=machine.Pin(22))
i2c.scan()
i2c.writeto(addr, b'1234')
i2c.readfrom(addr, 4)
Basic WiFi configuration:
import network
sta_if = network.WLAN(network.STA_IF); sta_if.active(True)
sta_if.scan() # Scan for available access points
sta_if.connect("<AP_name>", "<password>") # Connect to an AP
sta_if.isconnected() # Check for successful connection
Control commands:
CTRL-A -- on a blank line, enter raw REPL mode
CTRL-B -- on a blank line, enter normal REPL mode
CTRL-C -- interrupt a running program
CTRL-D -- on a blank line, do a soft reset of the board
CTRL-E -- on a blank line, enter paste mode
For further help on a specific object, type help(obj)
For a list of available modules, type help('modules')
.pre
^^ webrepl
.pre
dpavlin@klin:/klin/FPGA$ git clone https://github.com/hyperglitch/webrepl
.pre
You can send files from command-line:
.pre
dpavlin@x200:/mnt/nuc/FPGA/webrepl$ ./webrepl_cli.py -p ulx3s ../esp32ecp5/ecp5.py 192.168.3.130:/
op:put, host:192.168.3.130, port:8266, passwd:ulx3s.
../esp32ecp5/ecp5.py -> /ecp5.py
Remote WebREPL version: (1, 11, 0)
Sent 22777 of 22777 bytes
dpavlin@x200:/mnt/nuc/FPGA/webrepl$ ./webrepl_cli.py -p ulx3s ../esp32ecp5/uftpd.py 192.168.3.130:/
op:put, host:192.168.3.130, port:8266, passwd:ulx3s.
../esp32ecp5/uftpd.py -> /uftpd.py
Remote WebREPL version: (1, 11, 0)
Sent 19482 of 19482 bytes
.pre
^ open source toolchain
Just use kost's binary builds: https://github.com/alpin3/ulx3s/releases
Or nightly builds: https://github.com/open-tool-forge/fpga-toolchain/releases
*this is old and needs update*
* https://github.com/SymbiFlow/prjtrellis
.pre
dpavlin@klin:/klin/FPGA$ git clone https://github.com/SymbiFlow/prjtrellis
dpavlin@klin:/klin/FPGA/prjtrellis$ ./download-latest-db.sh
dpavlin@klin:/klin/FPGA/prjtrellis$ cd libtrellis/
dpavlin@klin:/klin/FPGA/prjtrellis/libtrellis$ sudo apt-get install libpython3-dev libboost-python-dev libboost-filesystem-dev libboost-thread-dev libboost-program-options-dev
dpavlin@klin:/klin/FPGA/prjtrellis/libtrellis$ cmake -DCMAKE_INSTALL_PREFIX=/usr/local .
dpavlin@klin:/klin/FPGA/prjtrellis/libtrellis$ make
sudo make install
dpavlin@klin:/klin/FPGA/nextpnr$ cmake -DARCH=ecp5 -DBUILD_GUI=OFF -DTRELLIS_ROOT=../prjtrellis/ .
make
make install
.pre
^ diamond
https://github.com/jandob/lattice-diamond-archlinux/blob/master/eth0DummyToggle
^^ docker
https://gitter.im/ulx3s/Lobby?at=5dff4b08d2dadb38935c570a
https://github.com/dok3r/diamond/
.pre
docker run -it -v /host/fpga:/fpga -- local /host/fpga will end up in /fpga in docker
yes path will be fine
you will be missing make
so inside container you need to yum install make
and yum install libxslt
export ETHMAC=b0:5a:da:XX:XX:XX
set your MAC
docker run -it -v /media/internal/FPGA:/fpga -e LM_LICENSE_FILE=/fpga/license.dat --mac-address=$ETHMAC --privileged --ipc host -v /dev/bus/usb/:/dev/bus/usb/ dok3r/diamond:latest
run docker
yum install make libxslt
go tu project inside fpga folder and find makefile for diamond and then just make
then you share it with docker container with -v /yourHOSTfpgadir:/fpgadockerdir -e LM_LICENSE_FILE=/fpgadockerdir
for version you need to use like this dok3r/diamond:version
versions are here
https://hub.docker.com/r/dok3r/diamond/tags
docker run -it -v /media/internal/FPGA:/fpga -e LM_LICENSE_FILE=/fpga/license.dat --mac-address=$ETHMAC --privileged --ipc host -v /dev/bus/usb/:/dev/bus/usb/ dok3r/diamond:v3.7
like this
Not understanding -v /media/internal/FPGA
that is my local FPGA folder with samples and license.dat
it will mount on docker /fpga
and I see now that I need to share prjtrallis folder to docker so it can do ecppll
docker run -it -v /media/internal/FPGA:/fpga -v /local/prjtrellis/libtrellis:/mt/scratch/tmp/openfpga/prjtrellis/libtrellis -e LM_LICENSE_FILE=/fpga/license.dat --mac-address=$ETHMAC --privileged --ipc host -v /dev/bus/usb/:/dev/bus/usb/ dok3r/diamond:v3.7
but for that we will need @kost
we probably need ecppll and tools already there and compiled with centos- maybe just binaries
.pre
^ NES
https://gitter.im/ulx3s/Lobby?at=5de033f49319bb5190a9c3b6
* https://github.com/ironsteel/nes_ecp5
* flash arbitrary data to flash: https://github.com/ironsteel/tools/commit/cb0c43b6681a52f1cc19b6b70ddd587a307da90c#diff-3b94c2a26ac88b4b2363e058acf1852fR2281
* list of idcode: https://github.com/SymbiFlow/prjtrellis/blob/master/devices.json
* ported to ulx3s: https://github.com/lawrie/nes_ecp5
^ oberon
https://gitter.im/ulx3s/Lobby?at=5e007d1e8897197969e3331c
So, I have now managed to build oberon with diamond 3.7.
What I have to do is:
1. Build it with diamond 3.11, which fails
2. mv clocks clocks_save
3. make clean
4. cp -r clocks_save clocks
5. run docker for diamond 3.7
6. edit synpbase/bin/config/platform_check to allow 5.* linux.
7. make
8. Use ujprog in host linux to upload generated bit file
Thanks @kost for adding for adding make and libxslt to the docker image. It would be useful if you could patch the platform_check to allow versions before 3.11 to run on 5.* linux.
I got a lot of errors in the diamond 3.7 docker build, but the .bit file was created.
I can now run oberon and can see windows on the screen, but I don't have a working mouse or keyboard. I would need Goran's USB board to get both mouse and keyboard.
@lawrie i fixed in latest v3.7 - just make sure that you're running latest:
docker pull dok3r/diamond:v3.7
woohoo! Cool
@kost I pulled the latest v3.7 about 10 minutes ago, but still had to edit platform_check.
synpbase/bin/config/platform_check has:
case $VERSION in
4.* | 3.* | 2.4.* | 2.6.* )
It needs:
case $VERSION in
5.* | 4.* | 3.* | 2.4.* | 2.6.* )
I did the docker pull to make sure I had the latest version.
I changed oberon makefile to generate clocks in already existing directory to get rid of annoying mkdir clocks
In my instructions above it is safer to do make ECPPLL=echo in docker, so that it does not try to use ecppll, but uses the saved clocks that were generated on host linux.
^ 21f repack from 25f image
.pre
ecpunpack --input ulx3s_25.bit --textcfg ulx3s_12f.config --idcode 0x41111043
ecppack --input ulx3s_12f.config --bit ulxs3_12f.bit --idcode 0x21111043
.pre
^ compress bitstream
.pre
ecppack --compress
.pre
^ esp32ps2
https://github.com/emard/esp32ps2
^ saxonsoc
^^ linux
Instructions at https://github.com/lawrie/saxonsoc-ulx3s-bin/tree/master/linux
work for me on 85f :-)
https://gitter.im/ulx3s/Lobby?at=5de8ba2f08d0c961b7f3a25f
.pre
git clone https://github.com/SpinalHDL/buildroot.git -b saxon buildroot
git clone https://github.com/SpinalHDL/linux.git -b vexriscv --depth 1 linux
cd buildroot
cp board/spinal/saxon_default/linux_nonet.config board/spinal/saxon_default/linux.config
# Add extra options to board/spinal/saxon_default/linux.config
make spinal_saxon_default_defconfig
make linux-rebuild all -j$(nproc)
output/host/bin/riscv32-linux-objcopy -O binary output/images/vmlinux output/images/Image
# Make sure Image is at least 116KB less than 4MB
.pre
^^ 85f version
https://gitter.im/ulx3s/Lobby?at=5dea74995ac7f22fb57055ae
https://github.com/lawrie/saxonsoc-ulx3s-bin/blob/master/linux/README.md
https://github.com/lawrie/saxonsoc-ulx3s-bin/tree/master/linux/u-boot
https://github.com/SpinalHDL/SaxonSoc/tree/dev/bsp/Ulx3sLinuxUboot
^^ leds
https://gitter.im/ulx3s/Lobby?at=5dec101f46397c721ca4c814
.pre
#!/bin/sh
cd /sys/class/gpio
echo 488 > export
echo out > gpio488/direction
for i in 1 0 1 0 1 0
do
sleep 0.1
echo $i > gpio488/value
done
.pre
^^ slirp
https://gitter.im/ulx3s/Lobby?at=5df1467d0616d6515e20d197
^^ modifications
https://gitter.im/ulx3s/Lobby?at=5dfced993e3f133894ca9b4b
^^ u-boot config for 85f with 64M SDRAM
Modify bootcmd to include:
.pre
load mmc 0:1 0x80000000 /boot/uImage
load mmc 0:1 0x81EF0000 /boot/dtb
fdt add 0x81EF0000
fdt memory 0x80000000 0x04000000
bootm 0x80000000 - 0x81EF0000
.pre
^^ ppp networking
* https://github.com/dok3r/ulx3s-saxonsoc/wiki/ulx3s-networking
* https://github.com/emard/esp32ppp
^^ smp support
https://gitter.im/ulx3s/Lobby?at=5f4ea80bd4f0f55ebbf6ec33
https://github.com/SpinalHDL/SaxonSoc/tree/dev-0.1/bsp/radiona/ulx3s/smp
Instructions there need a bit of modification to run on blue 85f board with 64Mb of ram:
.pre
# Sourcing the build script
source SaxonSoc/bsp/radiona/ulx3s/smp/source.sh
# Clone opensbi, u-boot, linux, buildroot, openocd
saxon_clone
# Build the FPGA bitstream
saxon_standalone_compile bootloader CFLAGS_ARGS="-DSDRAM_TIMING=AS4C32M16SB_7TCN_ps"
SDRAM_SIZE=64 saxon_netlist
FPGA_SIZE=85 saxon_bitstream
# Build the firmware
saxon_opensbi
saxon_uboot
saxon_buildroot
# Build the programming tools
saxon_standalone_compile sdramInit CFLAGS_ARGS="-DSDRAM_TIMING=AS4C32M16SB_7TCN_ps"
saxon_openocd
.pre
Copy generated bitstream
.pre
dpavlin@klin:/klin/FPGA/saxonsoc$ cp SaxonSoc/hardware/synthesis/radiona/ulx3s/smp/bin/toplevel.bit saxon.bit
dpavlin@klin:/klin/FPGA/saxonsoc$ gzip -9 saxon.bit
.pre
Transfer it using ftp
.pre
ftp> put saxon.bit.gz
local: saxon.bit.gz remote: saxon.bit.gz
200 OK
150 Opened data connection.
226 Done.
359484 bytes sent in 10.27 secs (34.1994 kB/s)
ftp> site saxon.bit.gz
.pre
u-boot will fail to boot if you have rootfs on second partition
.pre
SDRAM init
OpenSBI copy
U-Boot copy
OpenSBI boot
OpenSBI v0.6-8-gd7b62b8
____ _____ ____ _____
/ __ \ / ____| _ \_ _|
| | | |_ __ ___ _ __ | (___ | |_) || |
| | | | '_ \ / _ \ '_ \ \___ \| _ < | |
| |__| | |_) | __/ | | |____) | |_) || |_
\____/| .__/ \___|_| |_|_____/|____/_____|
| |
|_|
Platform Name : VexRiscv SMP simulation
Platform HART Features : RV32AIMS
Platform Max HARTs : 4
Current Hart : 0
Firmware Base : 0x80f80000
Firmware Size : 84 KB
Runtime SBI Version : 0.2
MIDELEG : 0x00000222
MEDELEG : 0x0000b101
U-Boot 2020.07-08304-gd361dd3997 (Sep 05 2020 - 09:45:52 +0200)
DRAM: 32 MiB
MMC: spi@10020000:mmc@1: 0
Loading Environment from FAT... Unable to use mmc 0:1... In: serial@10010000
Out: serial@10010000
Err: serial@10010000
Net: No ethernet found.
Hit any key to stop autoboot: 0
Wrong Image Format for bootm command
ERROR: can't get kernel image!
=>
.pre
https://github.com/dok3r/ulx3s-saxonsoc/wiki/SaxonSoc-on-ULX3s
.pre
setenv bootcmd "load mmc 0:1 0x80000000 /boot/uImage;load mmc 0:1 0x80FF0000 /boot/dtb;fdt add 0x80FF0000;fdt memory 0x80000000 0x04000000;bootm 0x80000000 - 0x80FF0000"
setenv bootargs "rootwait console=hvc0 root=/dev/mmcblk0p2 init=/sbin/init mmc_core.use_spi_crc=0"
saveenv
.pre
> Lawrie Griffiths @lawrie Sep 01 21:59
The new SaxonSoc is now working on a 12F for me. Here are the instructions to build from source - https://github.com/SpinalHDL/SaxonSoc/tree/dev-0.1/bsp/radiona/ulx3s/smp
The images and bitstream are here - https://github.com/lawrie/saxonsoc-ulx3s-bin/tree/master/Smp
There is no sdcard image at the moment, but all the files are there for you to build your own.
^ ov7670 pmod
https://github.com/goran-mahovlic/fpga-odysseus/tree/master/projects/OV7670-HDMI
pmod pin mapping:
https://github.com/goran-mahovlic/fpga-odysseus/blob/master/projects/OV7670-HDMI/ulx3s.lpf#L335
^^ SCCB Pullup Resistors
from https://github.com/westonb/OV7670-Verilog
The SCCB interface for the camera requires pull up resistors. You need to solder 4.7K resistors from the SIOD and SIOC pins on the camera to the 3.3V supply. You can do this yourself or have the staff in the EDS help you.
^^ ov7670_rgb_yuv_320x240_colorfilter
https://github.com/JdeRobot/FPGA-robotics/tree/master/Projects/ComputerVision
^^ nmigen
https://github.com/lawrie/ulx3s-nmigen-examples/blob/master/image/camtest.py
^ csi
https://twitter.com/mad_archer_/status/1231249513509261313
https://github.com/libv/fosdem-video-linux
^ litex
(just links, need to test it)
* https://gojimmypi.blogspot.com/2020/03/litex-soft-cpu-on-ulx3s-reloading.html
* https://github.com/timvideos/litex-buildenv/wiki/LiteX-for-Hardware-Engineers
* https://github.com/enjoy-digital/litex
^ spiram
https://gitter.im/ulx3s/Lobby?at=5ef22d4c54d7862dc4a42395
@Speccery thereis also commandline "spiram.py" for some low-level inspection, so to reset TI this works for me
>>> spiram.poke(0x100008,bytearray([0xFC]))
>>> spiram.poke(0x100008,bytearray([0xFF]))
and to read bytes
>>> spiram.peek(0,16)
bytearray(b'\x83\xe0\x00$\x83\xc0\t\x00\x83\xc0\n\x920\xaa\x04`')
^ led
.pre
ftx_prog --cbus 3 DRIVE_0 # green OFF
ftx_prog --cbus 3 SLEEP # green ON if enumerated
.pre
This is active after power cycle
^^ micropython blue led
.pre
>>> from machine import Pin
>>> led=Pin(5,Pin.OUT)
>>> led.on() # upali plavu
>>> led.off() # ugasi plavu
.pre
^ micropython
.pre
from upysh import *
.pre
^ TODO
try various projects for ulx3s
* https://gitlab.com/pnru/cortex
^ c64
part of https://github.com/lawrie/ulx3s_retro
https://github.com/emard/ulx3s_c64
.pre
dpavlin@klin:/klin/FPGA/ulx3s_c64/proj$ time make FPGA_SIZE=25
.pre
^ tfmicro on LiteX/VexRiscv
https://github.com/dlobato/tfmicro-on-litex-vexriscv
^ ML CNN accelerator
https://github.com/BracketMaster/maeri
^ kianRiscV
https://gitAhub.com/splinedrive/kianRiscV/tree/master/linux_socs/kianv_mc_rv32ima_sv32/demo
openFPGALoader -f -o $((1024*1024)) --board=ulx3s bootloader.bin
Linux installation on Apple iBook G4
Based on instructions from:
* http://people.debian.org/~branden/ibook.html
Download files from http://http.us.debian.org/debian/dists/testing/main/installer-powerpc/current/images/powerpc/netboot/ (except mini.iso) by alt+clink on filenames and put it in root folder of first HFS+ partition.
My df output follows:
.pre
mac:~ apollo$ df
Filesystem 512-blocks Used Avail Capacity Mounted on
/dev/disk0s3 18612224 16109544 2316560 87% /
devfs 195 195 0 100% /dev
fdesc 2 2 0 100% /dev
<volfs> 1024 1024 0 100% /.vol
/dev/disk0s5 79199360 46155456 33043904 58% /Volumes/ko3moc
automount -nsl [201] 0 0 0 100% /Network
automount -fstab [206] 0 0 0 100% /automount/Servers
automount -static [206] 0 0 0 100% /automount/static
.pre
{file: PCA9685.pdf}
{image: PCA9685.jpg}
16-channel, 12-bit PWM Fm+ I 2 C-bus LED controller
.pre
dpavlin@cubieboard:~$ zgrep 9685 /proc/config.gz
CONFIG_PWM_PCA9685=m
# on armbian this requires kernel recompile
root@cubieboard:~# i2cdetect -y 2
0 1 2 3 4 5 6 7 8 9 a b c d e f
00: -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: UU UU -- UU -- -- -- -- UU -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: 70 -- -- -- -- -- -- --
root@cubieboard:~# echo pca9685 0x70 > /sys/bus/i2c/devices/i2c-2/new_device
[Tue Jun 25 19:59:58 2019] i2c i2c-2: new_device: Instantiated device pca9685 at 0x70
root@cubieboard:/sys/devices/platform/soc/1c2b000.i2c/i2c-2/2-0070/pwm/pwmchip0# echo 0 > export
# Default period_ns = 1/200 Hz
root@cubieboard:/sys/devices/platform/soc/1c2b000.i2c/i2c-2/2-0070/pwm/pwmchip0/pwm0# echo 5000000 > period
root@cubieboard:/sys/devices/platform/soc/1c2b000.i2c/i2c-2/2-0070/pwm/pwmchip0/pwm0# cat period
5000000
root@cubieboard:/sys/devices/platform/soc/1c2b000.i2c/i2c-2/2-0070/pwm/pwmchip0/pwm0# cat duty_cycle
0
# move servo
root@cubieboard:/sys/devices/platform/soc/1c2b000.i2c/i2c-2/2-0070/pwm/pwmchip0/pwm0# echo 2000000 > duty_cycle
root@cubieboard:/sys/devices/platform/soc/1c2b000.i2c/i2c-2/2-0070/pwm/pwmchip0/pwm0# echo 1000000 > duty_cycle
.pre
^ sg90 servo motor
.pre
root@cubieboard:/sys/devices/platform/soc/1c2b000.i2c/i2c-2/2-0070/pwm/pwmchip0/pwm0# echo 20000000 > period # 50Hz
root@cubieboard:/sys/devices/platform/soc/1c2b000.i2c/i2c-2/2-0070/pwm/pwmchip0/pwm0# echo 1000000 > duty_cycle # min?
root@cubieboard:/sys/devices/platform/soc/1c2b000.i2c/i2c-2/2-0070/pwm/pwmchip0/pwm0# echo 3000000 > duty_cycle # max?
.pre
^ pictures
^^ position of plastic clips to unclip after removing screws
{file: innobox-v80-case-clips-20210522_192312.jpg}
^^ top of board
{file: innobox-v80-top-20210522_192339.jpg}
^^ bottom of board
{file: innobox-v80-back-20210522_192256.jpg}
^ software version
Hardware version: 1.0
Active image: 2
Firmware image 1: 1.0.839
Firmware image 2: 1.1.966
Checksum of image 1: 34e4b3948d00a869d961283510a7eb08
Checksum of image 2: a6e08754c908c237d1539cb143611697
Firmware bootloader: 1.9
CRC of bootloader: a6e08754c908c237d1539cb143611697
^ serial
4 pins, pin 1 marked with triangle
1: TX
2: RX
3: GND
4: 3V3 (?)
^ serial output
(partial)
.pre
BGA IC
Xtal:1
DDR3 init.
DRAMC init done.
Calculate size.
DRAM size=128MB
Set new TRFC.
7512DRAMC V1.2.2 (0)
EN751221 at Fri Apr 16 11:48:25 CST 2021 version 1.9 free bootbase
Memory size 128MB
Set SPI Clock to 50 Mhz
spi_nand_probe: mfr_id=0xc8, dev_id=0x21
Using Flash ECC.
Detected SPI NAND Flash : _SPI_NAND_DEVICE_ID_F50L1G, Flash Size=0x8000000
bmt pool size: 81
BMT & BBT Init Success
>>>> [get_env_info] hw_id:InnboxV80_PW2
>>>> [set_gpio_define] g_hw_id:InnboxV80_PW2
Reset button GPIO is: 0
Press any key in 3 secs to enter boot command mode.
............................................................
Invalid Power GPIO, just return and don't turn on Power LED
NAND FLASH
>>>> CTC: boot_flag_addr: 53e0fff; flag: 1 version_addr:53e1000 version:1.9<FF><FF><FF><FF>
==> boot flag = 1
Decompress to 80002000 free_mem_ptr=80E00000 free_mem_ptr_end=807B0000
from slave
Uncompressing [LZMA] ... done.
Initializing cgroup subsys cpuset
Initializing cgroup subsys cpu
Initializing cgroup subsys cpuacct
Linux version 3.18.21 (iskratel@2d7d74f016e9) (gcc version 4.6.3 (Buildroot 2015.08.1) ) #3 SMP Fri Apr 16 11:32:58 CST 2021
ISPRAM0: PA=00770000,Size=00010000,enabled
Config7: 0x80080500
memsize:120MB
EcoNet EN751221 SOC prom init
bootconsole [early0] enabled
CPU0 revision is: 00019558 (MIPS 34Kc)
Determined physical RAM map:
memory: 077fe000 @ 00002000 (usable)
Wasting 64 bytes for tracking 2 unused pages
Zone ranges:
Normal [mem 0x00002000-0x077fffff]
Movable zone start for each node
Early memory node ranges
node 0: [mem 0x00002000-0x077fffff]
Initmem setup node 0 [mem 0x00002000-0x077fffff]
Detected 1 available secondary CPU(s)
Primary instruction cache 64kB, VIPT, 4-way, linesize 32 bytes.
Primary data cache 32kB, 4-way, VIPT, cache aliases, linesize 32 bytes
PERCPU: Embedded 9 pages/cpu @810f3000 s5664 r8192 d23008 u36864
Built 1 zonelists in Zone order, mobility grouping on. Total pages: 30478
Kernel command line: es=1
PID hash table entries: 512 (order: -1, 2048 bytes)
Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
Writing ErrCtl register=0002e01a
Readback ErrCtl register=0002e01a
nmi base is 81124200
Memory: 110280K/122872K available (7640K kernel code, 1290K rwdata, 1624K rodata, 304K init, 551K bss, 12592K reserved)
SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
Hierarchical RCU implementation.
NR_IRQS:64
tc3162_time_init: Init bus timeout and watchdog
plat_set_irq_affinity: cpu 0
plat_set_irq_affinity: cpu 0 vpe_id 0
plat_set_irq_affinity: irq_vpe0 1 irq_vpe1 0, irq = 10
plat_set_irq_affinity: irq num 10
plat_set_irq_affinity: cpu 0
plat_set_irq_affinity: cpu 0 vpe_id 0
plat_set_irq_affinity: irq_vpe0 1 irq_vpe1 0, irq = 33
plat_set_irq_affinity: irq num 33
CPU frequency 900.00 MHz
plat_time_init: Entered, mips_timer_ack ptr is [80006dd4]
Using 200.000 MHz high precision timer.
r4k_clockevent_init: setup_irq OK, irq is [31]
console [ttyS0] enabled
console [ttyS0] enabled
bootconsole [early0] disabled
bootconsole [early0] disabled
Calibrating delay loop... 597.60 BogoMIPS (lpj=2988032)
pid_max: default: 32768 minimum: 301
.pre
^ boot loader
.pre
bldr> ?
? Print out help messages.
help Print out help messages.
go Booting the linux kernel.
decomp Decompress kernel image to ram.
memrl <addr> Read a word from addr.
memwl <addr> <value> Write a word to addr.
dump <addr> <len> Dump memory content.
jump <addr> Jump to addr.
flash <dst> <src> <len> <oob> Write to flash from src to dst(oob: write nand oob if 1).
imginfo Show images info.
spinand_rwtest Flash Test
bdstore <flash dst> <bin src> Do backdoor config store
bdshow Show backdoor config
bdswitch[1|0] Enable or disable backdoor function
ddrcalswitch[1|0] Enable or disable ddr calibration funciton
drambistswitch[0|1|2] disable or enable, and quick or normal test
xmdm <addr> <len> Xmodem receive to addr.
miir <phyaddr> <reg> Read ethernet phy reg.
miiw <phyaddr> <reg> <value> Write ethernet phy reg.
cpufreq <freq num> / <m> <n> Set CPU Freq <156~450>(freq has to be multiple of 6)
ipaddr <ip addr> Change modem's IP.
httpd Start Web Server
mtd
bldr> bdshow
back door config is not support NAND Flash
.pre
* Open firmware for RTD 2662/2660 http://openrtd2662.ru/
^ DAC
* http://bellard.org/dvbt/
* http://www.erikyyy.de/tempest/
^ Arduino
* http://dpeckett.com/vga-on-the-arduino-with-no-external-parts
I have been backing up whole disk image from Eee PC, and mounting it using loop file system to access partition in it. However, I have problems with GNU fdisk which reports 4Gb image as:
.pre
Disk /backup/eee/hda: 3 GB, 3997486080 bytes
255 heads, 63 sectors/track, 486 cylinders, total 7807590 sectors
Units = sectors of 1 * 512 = 512 bytes
.pre
Device Boot Start End Blocks Id System
/backup/eee/hda1 63 4803435 2409718 83 Linux
/backup/eee/hda2 4819563 7759395 1469947 83 Linux
/backup/eee/hda3 7775523 7775460 0 c FAT32 LBA
/backup/eee/hda4 7791588 7791525 0 ef EFI FAT
For a start, disk size is wrong:
.pre
$ ls -al hda
-rwxrwxrwx 1 dpavlin root 4001292288 2008-01-20 00:59 hda
.pre
And then, even more wrong, offsets of partition seem to be wrong. When same image is examined using fdisk from `util-linux`, sectors are reported like this:
.pre
Disk hda: 0 MB, 0 bytes
255 heads, 63 sectors/track, 0 cylinders, total 0 sectors
Units = sectors of 1 * 512 = 512 bytes
Disk identifier: 0x332b332a
.pre
Device Boot Start End Blocks Id System
hda1 63 4819499 2409718+ 83 Linux
hda2 4819500 7775459 1477980 83 Linux
hda3 7775460 7791524 8032+ c W95 FAT32 (LBA)
hda4 7791525 7807589 8032+ ef EFI (FAT-12/16/32)
And this is correct (let's ignore size for now). I can verify this by mounting second file system as:
.pre
sudo mount hda 1 -o loop,offset=`expr 4819500 \* 512`
.pre
This seems to be off-by-one error. There is "bug reported against Debian package"<http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=442332> which seems related, but than again, in my case I'm examining same disk image.
{toc: }
https://github.com/raphaelbs/esp32-cam-ai-thinker/blob/master/docs/about-esp32-cam.md
^ connection, flashing
connected to pl2303 serial
| pl2303 | esp32cam |
| 3v3 | not connected |
| rxd | UnR |
| rxd | UOT |
| gnd | GND |
| 5v | 5V |
{image: ESP32-CAM-pinout-new.png}
To program the board, I userd jumper to jump GPIO0 with GND pin next to it.
https://github.com/raphaelbs/esp32-cam-ai-thinker/blob/master/docs/esp32cam-pin-notes.md
^^ spi
SDI = IO12
SDO = IO13
SCK = IO14
CS = IO15
^ improved example app
https://github.com/easytarget/esp32-cam-webserver
.pre
cp myconfig.sample.h myconfig.h
vi myconfig.h
dpavlin@nuc:/nuc/esp32/esp32-cam-webserver$ platformio run
dpavlin@nuc:/nuc/esp32/esp32-cam-webserver$ pio run -t upload --upload-port /dev/ttyUSB2
"/home/dpavlin/.platformio/penv/bin/python" "/home/dpavlin/.platformio/packages/tool-esptoolpy/esptool.py" \
--chip esp32 --port "/dev/ttyUSB3" --baud 460800 --before default_reset --after hard_reset \
write_flash -z --flash_mode dio --flash_freq 40m --flash_size detect \
0x1000 /home/dpavlin/.platformio/packages/framework-arduinoespressif32/tools/sdk/bin/bootloader_dio_40m.bin \
0x8000 /nuc/esp32/esp32-cam-webserver/.pio/build/esp32cam/partitions.bin \
0xe000 /home/dpavlin/.platformio/packages/framework-arduinoespressif32/tools/partitions/boot_app0.bin \
0x10000 .pio/build/esp32cam/firmware.bin
.pre
^ timelapse
* https://bitluni.net/esp32camtimelapse
* https://github.com/bitluni/ESP32CamTimeLapse
^ ocr on device
https://github.com/jomjol/AI-on-the-edge-device
https://github.com/jomjol/AI-on-the-edge-device/wiki/Installation
Remove glue from lens (very hard, using sharp knife), and rotate lens by 45 degrees until
picture is sharp (I had to use pliers to do this).
.pre
dpavlin@nuc:/nuc/esp32/AI-on-the-edge-device$ vi sd-card/wlan.ini
dpavlin@nuc:/nuc/esp32/AI-on-the-edge-device/code$ pio run
dpavlin@nuc:/nuc/esp32/AI-on-the-edge-device/code$ pio run -v -t upload --upload-port /dev/ttyUSB3
"/home/dpavlin/.platformio/penv/bin/python" "/home/dpavlin/.platformio/packages/tool-esptoolpy/esptool.py" \
--chip esp32 --port "/dev/ttyUSB3" --baud 460800 --before default_reset --after hard_reset \
write_flash -z --flash_mode dio --flash_freq 40m --flash_size detect \
0x1000 /nuc/esp32/AI-on-the-edge-device/code/.pio/build/esp32cam/bootloader.bin \
0x8000 /nuc/esp32/AI-on-the-edge-device/code/.pio/build/esp32cam/partitions.bin \
0xd000 /nuc/esp32/AI-on-the-edge-device/code/.pio/build/esp32cam/ota_data_initial.bin \
0x10000 .pio/build/esp32cam/firmware.bin
# original flashing instructions
esptool write_flash 0x01000 bootloader.bin 0x08000 partitions.bin 0x10000 firmware.bin
# download raw picture
wget 192.168.3.112/img_tmp/raw.jpg
.pre
----
^ old, obsolete problems
It seems that my module is usually known as AI thinker variant. It has terrible picture which starts with huge green bias.
It also doesn't work for me in resolutions below 1024x768 (in current esp32 example as of 2019-08-02).
Plugging it into external 5V power supply did not helped much.
----
To solve green tint, I just left esp32cam module plugged in whole day and night. I guess that image sensor got discharged during night, but next day picture was fine.
Problem with image resolution was fixed by updating to more recent version of ESP32 support for Arduino (as of 2020-04-20 it works fine)
^ [Home Assistant]
https://jamesachambers.com/cheap-esp32-cam-home-assistant-esphome-camera-guide/
.pre
esphome:
name: esp32cam
friendly_name: esp32cam
esp32:
board: esp32cam
framework:
type: arduino
# Enable logging
logger:
level: VERBOSE
tx_buffer_size: 256
# Enable Home Assistant API
api:
encryption:
key: "MsJJJiDv9FTjZ1w8dfoy3Z8cQWjGOsk0m4Wgge0B+8w="
services: # change camera parameters on-the-fly
- service: camera_set_param
variables:
name: string
value: int
then:
- lambda: |-
bool state_return = false;
if (("contrast" == name) && (value >= -2) && (value <= 2)) { id(espcam).set_contrast(value); state_return = true; }
if (("brightness" == name) && (value >= -2) && (value <= 2)) { id(espcam).set_brightness(value); state_return = true; }
if (("saturation" == name) && (value >= -2) && (value <= 2)) { id(espcam).set_saturation(value); state_return = true; }
if (("special_effect" == name) && (value >= 0U) && (value <= 6U)) { id(espcam).set_special_effect((esphome::esp32_camera::ESP32SpecialEffect)value); state_return = true; }
if (("aec_mode" == name) && (value >= 0U) && (value <= 1U)) { id(espcam).set_aec_mode((esphome::esp32_camera::ESP32GainControlMode)value); state_return = true; }
if (("aec2" == name) && (value >= 0U) && (value <= 1U)) { id(espcam).set_aec2(value); state_return = true; }
if (("ae_level" == name) && (value >= -2) && (value <= 2)) { id(espcam).set_ae_level(value); state_return = true; }
if (("aec_value" == name) && (value >= 0U) && (value <= 1200U)) { id(espcam).set_aec_value(value); state_return = true; }
if (("agc_mode" == name) && (value >= 0U) && (value <= 1U)) { id(espcam).set_agc_mode((esphome::esp32_camera::ESP32GainControlMode)value); state_return = true; }
if (("agc_value" == name) && (value >= 0U) && (value <= 30U)) { id(espcam).set_agc_value(value); state_return = true; }
if (("agc_gain_ceiling" == name) && (value >= 0U) && (value <= 6U)) { id(espcam).set_agc_gain_ceiling((esphome::esp32_camera::ESP32AgcGainCeiling)value); state_return = true; }
if (("wb_mode" == name) && (value >= 0U) && (value <= 4U)) { id(espcam).set_wb_mode((esphome::esp32_camera::ESP32WhiteBalanceMode)value); state_return = true; }
if (("test_pattern" == name) && (value >= 0U) && (value <= 1U)) { id(espcam).set_test_pattern(value); state_return = true; }
if (true == state_return) {
id(espcam).update_camera_parameters();
}
else {
ESP_LOGW("esp32_camera_set_param", "Error in name or data range");
}
ota:
password: "09e4b58a1d186b8b33d100548f33d796"
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
power_save_mode: none
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "Esp32Cam Fallback Hotspot"
password: "GTIKgjitx2Re"
captive_portal:
# Example configuration entry
esp32_camera:
id: espcam
name: esp-cam
external_clock:
pin: GPIO0
frequency: 20MHz
i2c_pins:
sda: GPIO26
scl: GPIO27
data_pins: [GPIO5, GPIO18, GPIO19, GPIO21, GPIO36, GPIO39, GPIO34, GPIO35]
vsync_pin: GPIO25
href_pin: GPIO23
pixel_clock_pin: GPIO22
power_down_pin: GPIO32
resolution: 800x600
jpeg_quality: 10 # max. 63
max_framerate: 1.0fps
idle_framerate: 0.2fps
vertical_flip: true
horizontal_mirror: false
brightness: 2 # -2 to 2
contrast: 1 # -2 to 2
special_effect: none
# exposure settings
aec_mode: auto
aec2: false
ae_level: 0
aec_value: 300
# gain settings
agc_mode: auto
agc_gain_ceiling: 2x
agc_value: 0
# white balance setting
wb_mode: auto
output:
# white LED
- platform: ledc
channel: 2
pin: GPIO4
id: espCamLED
# red status light
- platform: gpio
pin:
number: GPIO33
inverted: True
id: gpio_33
light:
- platform: monochromatic
output: espCamLED
name: esp-cam light
- platform: binary
output: gpio_33
name: esp-cam led
switch:
- platform: restart
name: esp-cam restart
binary_sensor:
- platform: status
name: esp-cam status
.pre
Script to convert eagle sch file to pdf {file: eagle-sch2pdf.sh}
.pre
dpavlin@t61p:~/t61p/eagle$ wget ftp://ftp.cadsoft.de/eagle/program/6.6/eagle-lin-6.6.0.run
dpavlin@t61p:~/t61p/eagle$ sudo apt-get install libxrandr2:i386
# install
dpavlin@t61p:~/t61p/eagle$ bash eagle-lin-6.6.0.run
# run
dpavlin@t61p:~/t61p/eagle$ /home/dpavlin/eagle-6.6.0/bin/eagle
.pre
.pre
dpavlin@klin:/klin$ wget http://web.cadsoft.de/ftp/eagle/program/7.2/eagle-lin-7.2.0.run
dpavlin@klin:/klin$ sudo apt-get install libxrandr2:i386 libfontconfig1:i386
dpavlin@klin:/klin$ bash eagle-lin-7.2.0.run
.pre
From: Gélineau, Samuel - Montreal
Date: Thu, 1 Nov 2007 17:31:54 -0400
----
Hi,
Your svn2cvs testsuite failed on my machine, and I had to fix both the testsuite and the perl script. I assume it must have worked for you the last time you ran your testsuite, and I have no clue why. I`m using CVS 1.12.9.
.pre
> cd svn2cvs/src
.pre
Running ./test.sh, the first abnormal behaviour I notice is at svn commit 14, "remove everything":
.pre
...
+ svn rm $svnco/dir/*
D /dev/shm/test-svn-co/dir/bar
D /dev/shm/test-svn-co/dir/baz
D /dev/shm/test-svn-co/dir/keep
D /dev/shm/test-svn-co/dir/keep-dir
D /dev/shm/test-svn-co/dir/l1/bar
D /dev/shm/test-svn-co/dir/l1/baz
D /dev/shm/test-svn-co/dir/l1/l2/bar
D /dev/shm/test-svn-co/dir/l1/l2/baz
D /dev/shm/test-svn-co/dir/l1/l2/l3/bar
D /dev/shm/test-svn-co/dir/l1/l2/l3/baz
D /dev/shm/test-svn-co/dir/l1/l2/l3
D /dev/shm/test-svn-co/dir/l1/l2
D /dev/shm/test-svn-co/dir/l1
D /dev/shm/test-svn-co/dir/skip_add
D /dev/shm/test-svn-co/dir/with space
+ svn revert $svnco/dir/keep $svnco/dir/keep-dir/keep
Reverted '/dev/shm/test-svn-co/dir/keep'
Skipped '/dev/shm/test-svn-co/dir/keep-dir/keep'
+ svn commit -m 'remove everything' $svnco
Deleting /dev/shm/test-svn-co/dir/bar
Deleting /dev/shm/test-svn-co/dir/baz
Deleting /dev/shm/test-svn-co/dir/keep-dir
Deleting /dev/shm/test-svn-co/dir/l1
Deleting /dev/shm/test-svn-co/dir/skip_add
Deleting /dev/shm/test-svn-co/dir/with space
Committed revision 14.
...
.pre
The interesting lines are:
.pre
Skipped '/dev/shm/test-svn-co/dir/keep-dir/keep'
...
Deleting /dev/shm/test-svn-co/dir/keep-dir
.pre
It`s obvious from the "svn revert" line that you never intended keep-dir to be deleted, yet it does gets deleted. I`m using svn 1.3.1 (r19032).
This time, the fix is in the testsuite itself:
.pre
--- svn2cvs/src/test.sh 2007-11-01 19:41:19.000000000 +0000
+++ svn2cvs/src/test.sh 2007-11-01 19:49:37.000000000 +0000
@@ -145,7 +145,7 @@
test
svn rm $svn_co/dir/* || exit
-svn revert $svn_co/dir/keep $svn_co/dir/keep-dir/keep
+svn revert $svn_co/dir/keep $svn_co/dir/keep-dir{,/keep}
svn commit -m "remove everything" $svn_co || exit
test
.pre
The relevant commit in the new testsuite now runs as follows:
.pre
...
+ svn rm $svnco/dir/*
D /dev/shm/test-svn-co/dir/bar
D /dev/shm/test-svn-co/dir/baz
D /dev/shm/test-svn-co/dir/keep
D /dev/shm/test-svn-co/dir/keep-dir
D /dev/shm/test-svn-co/dir/l1/bar
D /dev/shm/test-svn-co/dir/l1/baz
D /dev/shm/test-svn-co/dir/l1/l2/bar
D /dev/shm/test-svn-co/dir/l1/l2/baz
D /dev/shm/test-svn-co/dir/l1/l2/l3/bar
D /dev/shm/test-svn-co/dir/l1/l2/l3/baz
D /dev/shm/test-svn-co/dir/l1/l2/l3
D /dev/shm/test-svn-co/dir/l1/l2
D /dev/shm/test-svn-co/dir/l1
D /dev/shm/test-svn-co/dir/skip_add
D /dev/shm/test-svn-co/dir/with space
+ svn revert $svnco/dir/keep $svnco/dir/keep-dir $svnco/dir/keep-dir/keep
Reverted '/dev/shm/test-svn-co/dir/keep'
Reverted '/dev/shm/test-svn-co/dir/keep-dir'
Skipped '/dev/shm/test-svn-co/dir/keep-dir/keep'
+ svn commit -m 'remove everything' $svnco
Deleting /dev/shm/test-svn-co/dir/bar
Deleting /dev/shm/test-svn-co/dir/baz
Deleting /dev/shm/test-svn-co/dir/l1
Deleting /dev/shm/test-svn-co/dir/skip_add
Deleting /dev/shm/test-svn-co/dir/with space
Committed revision 14.
...
.pre
This time, the "skip" is legitimate. The testsuite still fails, though:
.pre
...
+ diff -x '.svn*' -x CVS -urw $svnco/dir/ $cvsco/dir/
Only in /dev/shm/test-cvs-co//dir/: l1
Only in /dev/shm/test-cvs-co//dir/: with space
+ exit
.pre
It again failed at this problematic last commit, "remove everything":
.pre
...
Starting after revision 13
## svn export --force -q -r 14 file:///dev/shm/test-svn-rep//dir /tmp/checkoutGGpuy/dir
NOTICE: using /dir as directory for svn
-------------------------------------------------------------------------------
r 14| gelineaus | 2007-11-01T20:22:39.115442Z
remove everything
svn2cvs: D /dir/bar
#### remove file: bar at ./svn2cvs.pl line 402.
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'bar'
cvs remove: scheduling `bar' for removal
cvs remove: use `cvs commit' to remove this file permanently
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'bar'
/dev/shm/test-cvs-rep/dir/bar,v <-- bar
new revision: delete; previous revision: 1.1
svn2cvs: D /dir/with space
WARNING: with space is not present in CVS, skipping...
svn2cvs: D /dir/baz
#### remove file: baz at ./svn2cvs.pl line 402.
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'baz'
cvs remove: scheduling `baz' for removal
cvs remove: use `cvs commit' to remove this file permanently
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'baz'
/dev/shm/test-cvs-rep/dir/baz,v <-- baz
new revision: delete; previous revision: 1.1
svn2cvs: D /dir/l1
WARNING: l1 is not present in CVS, skipping...
svn2cvs: D /dir/skip_add
#### remove file: skip_add at ./svn2cvs.pl line 402.
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'skip_add'
cvs remove: scheduling `skip_add' for removal
cvs remove: use `cvs commit' to remove this file permanently
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'skip_add'
/dev/shm/test-cvs-rep/dir/skip_add,v <-- skip_add
new revision: delete; previous revision: 1.1
commit ignored, no files
subversion revision 14 commited to CVS
/dev/shm/test-cvs-rep/dir/.svnrev,v <-- .svnrev
new revision: 1.15; previous revision: 1.14
+ update_all
+ update_svn
+ svn update /dev/shm/test-svn-co/
At revision 14.
+ update_cvs
+ cd /dev/shm/test-cvs-co/
+ cvs -f update -d dir
cvs update: Updating dir
U dir/.svnrev
cvs update: `dir/bar' is no longer in the repository
cvs update: `dir/baz' is no longer in the repository
cvs update: `dir/skip_add' is no longer in the repository
cvs update: Updating dir/keep-dir
cvs update: Updating dir/l1
cvs update: Updating dir/l1/l2
cvs update: Updating dir/l1/l2/l3
cvs update: Updating dir/with space
+ cd-
+ diff -x '.svn*' -x CVS -urw /dev/shm/test-svn-co//dir/ /dev/shm/test-cvs-co//dir/
Only in /dev/shm/test-cvs-co//dir/: l1
Only in /dev/shm/test-cvs-co//dir/: with space
+ exit
.pre
The relevant lines are:
.pre
...
svn2cvs: D /dir/with space
WARNING: with space is not present in CVS, skipping...
...
svn2cvs: D /dir/l1
WARNING: l1 is not present in CVS, skipping...
...
Only in /dev/shm/test-cvs-co//dir/: l1
Only in /dev/shm/test-cvs-co//dir/: with space
+ exit
.pre
In other words, svn2cvs.pl cannot see directories and refuses to remove them. This is because of the in_entries() function, which does not consider lines describing directories. Here`s the fix:
.pre
--- svn2cvs/src/svn2cvs.pl 2007-11-01 20:21:22.000000000 +0000
+++ svn2cvs/src/svn2cvs.pl 2007-11-01 20:36:52.000000000 +0000
@@ -263,6 +263,7 @@ sub in_entries($) {
|| return 0; #die "no entries file: $dir/CVS/Entries";
while (<$fh>) {
return 1 if (m{^/$file/});
+ return 1 if (m{^D/$file/});
}
close($fh);
return 0;
.pre
But the problematic last commit _still_ fails:
.pre
Starting after revision 13
## svn export --force -q -r 14 file:///dev/shm/test-svn-rep//dir /tmp/checkout1jkCl/dir
NOTICE: using /dir as directory for svn
-------------------------------------------------------------------------------
r 14| gelineaus | 2007-11-01T20:53:32.113268Z
remove everything
svn2cvs: D /dir/bar
#### remove file: bar at ./svn2cvs.pl line 403.
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'bar'
cvs remove: scheduling `bar' for removal
cvs remove: use `cvs commit' to remove this file permanently
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'bar'
/dev/shm/test-cvs-rep/dir/bar,v <-- bar
new revision: delete; previous revision: 1.1
svn2cvs: D /dir/with space
#### remove directory: with space at ./svn2cvs.pl line 383.
#### entries(with space) => at ./svn2cvs.pl line 249.
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'with space'
cvs remove: Removing with space
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'with space'
cvs commit: Examining with space
## cvs -f -d /dev/shm/test-cvs-rep/ update -dP .
cvs update: Updating .
cvs update: Updating keep-dir
cvs update: Updating l1
cvs update: Updating l1/l2
cvs update: Updating l1/l2/l3
cvs update: Updating with space
svn2cvs: D /dir/baz
#### remove file: baz at ./svn2cvs.pl line 403.
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'baz'
cvs remove: scheduling `baz' for removal
cvs remove: use `cvs commit' to remove this file permanently
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'baz'
/dev/shm/test-cvs-rep/dir/baz,v <-- baz
new revision: delete; previous revision: 1.1
svn2cvs: D /dir/l1
#### remove directory: l1 at ./svn2cvs.pl line 383.
#### entries recurse into: l1/l2 at ./svn2cvs.pl line 239, <$fh> line 3.
#### entries recurse into: l1/l2/l3 at ./svn2cvs.pl line 239, <> line 3.
#### entries(l1/l2/l3) => bar|baz at ./svn2cvs.pl line 249.
#### entries(l1/l2) => bar|baz|l3/bar|l3/baz|l3 at ./svn2cvs.pl line 249.
#### entries(l1) => bar|baz|l2/bar|l2/baz|l2/l3/bar|l2/l3/baz|l2/l3|l2 at ./svn2cvs.pl line 249.
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'l1/bar'
cvs remove: scheduling `l1/bar' for removal
cvs remove: use `cvs commit' to remove this file permanently
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'l1/bar'
/dev/shm/test-cvs-rep/dir/l1/bar,v <-- bar
new revision: delete; previous revision: 1.1
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'l1/baz'
cvs remove: scheduling `l1/baz' for removal
cvs remove: use `cvs commit' to remove this file permanently
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'l1/baz'
/dev/shm/test-cvs-rep/dir/l1/baz,v <-- baz
new revision: delete; previous revision: 1.1
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'l1/l2/bar'
cvs remove: scheduling `l1/l2/bar' for removal
cvs remove: use `cvs commit' to remove this file permanently
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'l1/l2/bar'
/dev/shm/test-cvs-rep/dir/l1/l2/bar,v <-- bar
new revision: delete; previous revision: 1.2
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'l1/l2/baz'
cvs remove: scheduling `l1/l2/baz' for removal
cvs remove: use `cvs commit' to remove this file permanently
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'l1/l2/baz'
/dev/shm/test-cvs-rep/dir/l1/l2/baz,v <-- baz
new revision: delete; previous revision: 1.2
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'l1/l2/l3/bar'
cvs remove: scheduling `l1/l2/l3/bar' for removal
cvs remove: use `cvs commit' to remove this file permanently
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'l1/l2/l3/bar'
/dev/shm/test-cvs-rep/dir/l1/l2/l3/bar,v <-- bar
new revision: delete; previous revision: 1.3
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'l1/l2/l3/baz'
cvs remove: scheduling `l1/l2/l3/baz' for removal
cvs remove: use `cvs commit' to remove this file permanently
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'l1/l2/l3/baz'
/dev/shm/test-cvs-rep/dir/l1/l2/l3/baz,v <-- baz
new revision: delete; previous revision: 1.3
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'l1/l2/l3'
cvs remove: Removing l1/l2/l3
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'l1/l2/l3'
cvs commit: Examining l1/l2/l3
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'l1/l2'
cvs remove: Removing l1/l2
cvs remove: Removing l1/l2/l3
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'l1/l2'
cvs commit: Examining l1/l2
cvs commit: Examining l1/l2/l3
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'l1'
cvs remove: Removing l1
cvs remove: Removing l1/l2
cvs remove: Removing l1/l2/l3
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'l1'
cvs commit: Examining l1
cvs commit: Examining l1/l2
cvs commit: Examining l1/l2/l3
## cvs -f -d /dev/shm/test-cvs-rep/ update -dP .
cvs update: Updating .
cvs update: Updating keep-dir
cvs update: Updating l1
cvs update: Updating l1/l2
cvs update: Updating l1/l2/l3
cvs update: Updating with space
svn2cvs: D /dir/skip_add
#### remove file: skip_add at ./svn2cvs.pl line 403.
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'skip_add'
cvs remove: scheduling `skip_add' for removal
cvs remove: use `cvs commit' to remove this file permanently
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'skip_add'
/dev/shm/test-cvs-rep/dir/skip_add,v <-- skip_add
new revision: delete; previous revision: 1.1
commit ignored, no files
subversion revision 14 commited to CVS
/dev/shm/test-cvs-rep/dir/.svnrev,v <-- .svnrev
new revision: 1.15; previous revision: 1.14
+ update_all
+ update_svn
+ svn update /dev/shm/test-svn-co/
At revision 14.
+ update_cvs
+ cd /dev/shm/test-cvs-co/
+ cvs -f update -d dir
cvs update: Updating dir
U dir/.svnrev
cvs update: `dir/bar' is no longer in the repository
cvs update: `dir/baz' is no longer in the repository
cvs update: `dir/skip_add' is no longer in the repository
cvs update: Updating dir/keep-dir
cvs update: Updating dir/l1
cvs update: `dir/l1/bar' is no longer in the repository
cvs update: `dir/l1/baz' is no longer in the repository
cvs update: Updating dir/l1/l2
cvs update: `dir/l1/l2/bar' is no longer in the repository
cvs update: `dir/l1/l2/baz' is no longer in the repository
cvs update: Updating dir/l1/l2/l3
cvs update: `dir/l1/l2/l3/bar' is no longer in the repository
cvs update: `dir/l1/l2/l3/baz' is no longer in the repository
cvs update: Updating dir/with space
+ cd-
+ diff -x '.svn*' -x CVS -urw /dev/shm/test-svn-co//dir/ /dev/shm/test-cvs-co//dir/
Only in /dev/shm/test-cvs-co//dir/: l1
Only in /dev/shm/test-cvs-co//dir/: with space
+ exit
.pre
The relevant lines are:
.pre
...
svn2cvs: D /dir/with space
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'with space'
cvs remove: Removing with space
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'with space'
...
## cvs -f -d /dev/shm/test-cvs-rep/ delete 'l1'
cvs remove: Removing l1
cvs remove: Removing l1/l2
cvs remove: Removing l1/l2/l3
## cvs -f -d /dev/shm/test-cvs-rep/ commit -m 'remove everything' 'l1'
...
Only in /dev/shm/test-cvs-co//dir/: l1
Only in /dev/shm/test-cvs-co//dir/: with space
+ exit
.pre
Thus cvs was asked to delete the directories, but didn`t. This is no surprise, since CVS was _designed_ not to remove directories. From the CVS manual:
> 7.3 Removing directories
> In concept, removing directories is somewhat similar to removing files--you want the directory to not exist in your current working directories, but you also want to be able to retrieve old releases in which the directory existed.
> The way that you remove a directory is to remove all the files in it. You don't remove the directory itself; there is no way to do that. Instead you specify the '-P' option to cvs update or cvs checkout, which will cause CVS to remove empty directories from working directories. (Note that cvs export always removes empty directories.) Probably the best way to do this is to always specify '-P'; if you want an empty directory then put a dummy file (for example '.keepme') in it to prevent '-P' from removing it.
> Note that '-P' is implied by the '-r' or '-D' options of checkout. This way, CVS will be able to correctly create the directory or not depending on whether the particular version you are checking out contains any files in that directory.
Thus the fix would be to automatically add a ".keepme" file upon directory creation, and to removed it (along with the other files in the directory) upon directory deletion. The testsuite also needs to be updated to use the "-P" flag. Thus, my last patch:
.pre
diff -r -uprN svn2cvs/src/svn2cvs.pl svn2cvs/src/svn2cvs.pl
--- svn2cvs/src/svn2cvs.pl 2007-11-01 20:36:52.000000000 +0000
+++ svn2cvs/src/svn2cvs.pl 2007-11-01 21:06:04.000000000 +0000
@@ -104,7 +104,8 @@ sub add_dir($$) {
next if in_entries($curr_dir);
next if ( -e "$curr_dir/CVS" );
+ log_system( "touch '$curr_dir/.keepme'", "creation of .keepme file (to keep $curr_dir alive in CVS) failed" );
- log_system( "$cvs add '$curr_dir'", "cvs add of $curr_dir failed" );
+ log_system( "$cvs add '$curr_dir' '$curr_dir/.keepme'", "cvs add of $curr_dir failed" );
}
}
diff -r -uprN svn2cvs/src/test.sh svn2cvs/src/test.sh
--- svn2cvs/src/test.sh 2007-11-01 20:36:32.000000000 +0000
+++ svn2cvs/src/test.sh 2007-11-01 21:06:39.000000000 +0000
@@ -52,13 +52,13 @@ cd- || exit
rm -Rf $cvs_co || exit
mkdir $cvs_co || exit
-cd $cvs_co && cvs -f co dir && cd- || exit
+cd $cvs_co && cvs -f co -P dir && cd- || exit
function svn2cvs() {
./svn2cvs.pl file://$svn_rep/dir $cvs_rep dir || exit
}
function update_cvs() {
- cd $cvs_co && cvs -f update -d dir && cd- || exit
+ cd $cvs_co && cvs -f update -P -d dir && cd- || exit
}
function update_svn() {
svn update $svn_co || exit
@@ -70,7 +70,7 @@ function update_all() {
function test() {
svn2cvs
update_all
- diff -x .svn\* -x CVS -urw $svn_co/dir/ $cvs_co/dir/ || exit
+ diff -x .svn\* -x CVS -x '\.keep' -urw $svn_co/dir/ $cvs_co/dir/ || exit
}
svn2cvs
.pre
And now the problematic test finally passes.
Hoping to be useful,
* Samuel Gélineau
----
This is one of best bug reports I ever received or actually read :-) It seems that "other projects also appriciate bug reports"<http://dev.eclipse.org/mhonarc/lists/aspectj-announce/msg00055.html> like:
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=96111
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=98320
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=98592
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=99168
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=99228
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=100227
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=100260
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=102212
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=102357
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=104024
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=105181
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=106630
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=106634
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=106874
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=107059
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=107858
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=107898
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=108014
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=104046
{toc: }
^ 2.2 TFT LCD: TFT01-2.2SP
http://www.elecfreaks.com/estore/2-2-tft-lcd-tft01-2-2sp.html
http://www.elecfreaks.com/wiki/index.php?title=2.2S%22_TFT_LCD:_TFT01-2.2S
ILI9341 (or ILI9340 according to tftfb)
{image: pinout-2.2SP.jpg}
^ [RaspberryPi]
https://github.com/notro/fbtft/wiki
https://hackaday.io/project/6157/instructions
https://www.raspberrypi.org/forums/viewtopic.php?p=768868#p768868
* VCC to 3.3 volt (pin 17)
* GND to GND (pin 20)
* CS to CE0 (pin 24)
* RESET to GPIO 25 (pin 22)
* D/C to GPIO 24 (pin 18)
* SDI/MOSI to MOSI (pin 19)
* SCK to SCLk (pin 23)
* LED to GPIO18 (pin 12)
* SDO/MISO to MISO (pin 21)
.pre
# enable spi in raspi-config
pi@jpi1 ~ $ grep spi /boot/config.txt
dtparam=spi=on
sudo REPO_URI=https://github.com/notro/rpi-firmware rpi-update
sudo reboot
pi@jpi1 ~ $ sudo modprobe fbtft_device name=adafruit22a verbose=1
pi@jpi1 ~ $ dmesg | tail -8
[ 173.796933] fbtft_device: Deleting spi0.0
[ 173.797590] spi spi0.0: setting up native-CS0 as GPIO 8
[ 173.797807] fbtft_device: GPIOS used by 'adafruit22a':
[ 173.797833] fbtft_device: 'reset' = GPIO25
[ 173.797851] fbtft_device: 'dc' = GPIO24
[ 173.797864] fbtft_device: 'led' = GPIO18
[ 173.838265] fb_ili9340: module is from the staging directory, the quality is unknown, you have been warned.
[ 174.220426] graphics fb1: fb_ili9340 frame buffer, 240x320, 150 KiB video memory, 4 KiB DMA buffer memory, fps=20, spi0.0 at 32 MHz
pi@jpi1 ~ $ fbset -fb /dev/fb1
mode "240x320"
geometry 240 320 240 320 16
timings 0 0 0 0 0 0 0
nonstd 1
rgba 5/11,6/5,5/0,0/0
endmode
pi@jpi1 ~ $ cat /dev/urandom > /dev/fb1
cat: write error: No space left on device
# test
cd /usr/share/X11/xorg.conf.d/
sudo mv 99-fbturbo.conf ~/
FRAMEBUFFER=/dev/fb1 startx
.pre
{toc: }
There are many on-line resources about RFID. However, most of them are not well suited for beginners. So, if you just got RFID reader (3M in this case) and want high-level overview of what it is and what it can do, you are out of luck.
Until now, that is. This guide should help you decide if RFID is right thing for your library and when you make choice to implement it, how to do it.
This document will describe my experience with 3M 810 reader using RFID 501: RFID Standards for Libraries {file: RFID_501.pdf}
^ RFID tag
Best way to think about RFID tags is like contact-less readable barcode.
Our particular tags come in two form: RFID stickers (to be placed on books) and plastic credit-card like cards (we use them for patrons).
Have in mind that established practice is to have different RFID systems for books and patrons (we are use same one). When we asked about using same system for books and patrons, we got reply: "we don't have experience with it".
In practice, we have problem with 3M selfcheck software in some special conditions where book reader have patron card in range it gets network connection error with SIP server.
Since normal configuration of selfcheck stations is to have two different systems for patrons and books this problem doesn't show up for other users.
Each tag has unique serial number (SID) assigned by manufacturer and used in RFID collision detection protocol. It looks like hexadecimal number starting with letter `E0` like this: `E00401003123AA26`.
It's best to think of SID as unique identifier of physical tag.
Your information system will have it's own ID (barcode?) for some item.
There are cases in which you might want to change physical tag sticker on book because it's damaged. In that case, you will change SID of that item, but not barcode (which is data programmed on tag itself).
Our initial idea was to use data programmed on chip for everything, and just ignore SIDs, but we found out that there is class of RFID devices which can read ONLY SID from chip (in our case it's photocopying system).
3M software does record SIDs to log file when programming chips, but that's all. It essential ignores it for all practical intends and purposes.
Chips have 7 blocks of user data on it, each block with 4 bytes which enables us to store 28 bytes of user specified data on each tag.
^^ blank tag
^^^ 3M Manufacturing Blank
Easiest case is blank tag, in which all data on chip is 0x55
.pre
0 55 55 55 55 blank tag
1 55 55 55 55
2 55 55 55 55
3 55 55 55 55
4 55 55 55 55
5 55 55 55 55
6 00 00 00 00
.pre
^^^ Generic blank
Generic blank seems to erase only first three blocks with zeros:
.pre
00 00 00 00 00
01 00 00 00 00
02 00 00 00 00
.pre
while rest of tag will be unchanged *including rest of data on tag*
^^ programmed tag
Tags programmed with 3M software have following data layout on them:
.pre
0 04 is 00 tt i [4 bit] = number of item in set [1 .. i .. s]
s [4 bit] = total items in set
tt [8 bit] = item type
1 dd dd dd dd dd [16 bytes] = barcode data
2 dd dd dd dd
3 dd dd dd dd
4 dd dd dd dd
5 bb bl ll ll b [12 bit] = branch [unsigned]
l [20 bit] = library [unsigned]
6 cc cc cc cc c [32 bit] = custom signed integer
.pre
This basically means that your barcode or identifier of item or patron can have up to 16 characters (by default numeric, but you can extend that to handle alphanumeric and special character if you need that) and three integer values: branch `0 .. 4095`, library `0 .. 1048575` and custom data `-2147483648 .. 2147483647`.
You might want to use those values to uniquely identify your library and branch so that your RFID tags in books won't collide with other libraries.
If you leave decision just to providers of equipment, you might end up with 300000 tags which have plain and simple 0 in those fields. Guess which value will have tags of next library which that provider will have? My guess would be 0 also.
Writing correct numbers in that fields is not enough. If you want to use 3M software, you will also have to setup it to ignore all other tags which doesn't match your library and branch.
^^ security
There is also single byte called AFI or security which can be changed without accessing content of chip. This byte is also readable by more primitive RFID devices like doors to check if book have been checked out from library.
3M is using `0xD7` (215) value for secured items (door will beep) and `0xDA` (218) as unsecured. It seems that all other values are ignored.
(I would guess that other manufacturers are using different values)
As I mentioned before, since we don't have any special values in branch, library or custom field, we have situations in which patron cards get secured when patron walks by checkout counter and 3M software is left in checkout mode.
This triggers door to ring when patron passes which is not ideal.
^^ disable tag
3M software have option to disable tags. Initial examination showed that it's simply programming of tag with following content:
.pre
00 ff 00 00 00
01 00 00 00 00
02 00 00 00 00
03 00 00 00 00
04 00 00 00 00
05 00 00 00 00
06 00 00 00 00
.pre
and security set to `d7` (this might be value from tag before disabling it, I'll have to re-check this)
While 3M software will ignore tags programmed with this content, there is *not permanent disabling of tag* since it can be programmed using other software.
^ RFID reader device
Reader consists of several part:
* black pad - reader antenna
* reader - small box with micro controller and usb port
* software
Reader is recognized as USB serial device with it's own protocol on serial port. We are mostly interested in it's protocol and our ability to use reader and tags with our custom software.
At first, I assumed that protocol with RFID readers is some kind of standard.
After extensive search on Internet I wasn't able to find any documentation about this particular protocol (I even tried to compare it with existing open source implementations just to be sure).
So, only solution was to do clean-room reverse engineering, and using that technique I developed perl module which can talk with RFID reader which is available at http://svn.rot13.org/index.cgi/RFID
After initial reverse engineering of protocol I rewrote support for 3M and CPR reader which is available at https://github.com/dpavlin/Biblio-RFID
^ Related blog posts
{fetchrss: http://mjesec.ffzg.hr/~dpavlin/blog/mt/mt-search.cgi?tag=RFID&Template=feed&IncludeBlogs=1}
^ More information
If this was too geeky for you here is some additional materials:
* "RFID for libraries FAQ"<http://www.bibliotheca-rfid.com/faq>
* "RFID - overview of protocols, librfid implementation and passive sniffing"<http://events.ccc.de/congress/2005/fahrplan/events/769.en.html>
^ ISO standard
* ISO 15962.2004 - object identifier structure
* ISO 15693 - RFID (layer 2)
* ISO 18000 Part 3 Mode 1 - 13.56MHz
* "ISO/IEC JTC1/SC17/WG8"<http://www.incits.org/tc_home/b105htm/b105Doc2003/N03-140-WG8-Work-Project.htm>
^ ISO/IEC 14443, Proximity cards
The Standard series ISO/IEC 14443 consists of 4 parts, which are:
^^ ISO/IEC 14443-1 Physical characteristics
{file: 17n1363t.doc} {file: 17n1363b.doc}
^^ ISO/IEC 14443-2 Radio frequency power and signal interface
{file: 17n1522t.pdf} {file: 17n1522c.doc}
^^ ISO/IEC 14443-2/AMD2 Amendment 2: Bit rates of fc/64, fc/32 and fc/16
{file: 17n2343T.pdf} {file: 17n2343F.doc}
^^ ISO/IEC 14443-3 Initialization and anticollision
{file: 17n1531t.pdf} {file: 17n1531c.doc}
^^ ISO/IEC 14443-3 Amendment 1: Bit rates of fc/64, fc/32 and fc/16
{file: 17n2342T.pdf} {file: 17n2342F.doc}
^^ ISO/IEC 14443-4 Transmission protocol
{file: 17N1689T.pdf} {file: 17n1689c.doc}
^ ISO/IEC 15693, Vicinity cards
^^ ISO/IEC 15693-1 Physical characteristics
{file: 17n1355t.doc} {file: 17n1355b .doc}
^^ ISO/IEC 15693-2 Air interface and initialisation
{file: 17n1486.pdf} {file: 17n1486c.doc}
^^ ISO/IEC 15693-3 Anticollision and transmission protocol
{file: 17n1692t.pdf} {file: 17n1692c.doc}
^ ISO/IEC 10373-6, 10373-7, Test methods for the contactless integrated circuit(s) cards
^^ ISO/IEC 10373-6 Proximity cards
{file: 17n1695t.pdf} {file: 17n1695c.doc}
^^ ISO/IEC 10373-6/AMD1 Amendment 1: Additional PICC test methods
{file: 17n2258t.pdf} {file: 17n2258t.doc} {file: 17n2258C.doc}
^^ ISO/IEC 10373-6/AMD2 Amendment 2: Improved RF test methods
{file: 17n2225t.pdf} {file: 17n2225F.doc}
^^ ISO/IEC 10373-7 Vicinity cards
{file: 17n1697t.pdf} {file: 17n1697c.doc}
^ ISO/IEC 10536, Close-coupled cards
^^ ISO/IEC 10536-1 Physical characteristics
{file: 17n1480t.PDF} {file: 17n1480c.doc}
{image: Bluepillpinout.gif}
{toc}
^ Black Magic Probe
https://github.com/blacksphere/blackmagic
^ links
* https://github.com/blacksphere/blackmagic/pull/198/files
* https://embdev.net/articles/STM_Discovery_as_Black_Magic_Probe
* stlink clone https://github.com/blacksphere/blackmagic/issues/62
* https://github.com/jsnyder/stm32loader
^ blue pill
http://wiki.stm32duino.com/index.php?title=Blue_Pill
.pre
dpavlin@klin:/rest/cvs/blackmagic/src$ make PROBE_HOST=stli
LD blackmagic
/usr/lib/gcc/arm-none-eabi/5.4.1/../../../arm-none-eabi/bin/ld: address 0x8010dd0 of blackmagic section `.text' is not within region `rom'
/usr/lib/gcc/arm-none-eabi/5.4.1/../../../arm-none-eabi/bin/ld: blackmagic section `.data' will not fit in region `rom'
/usr/lib/gcc/arm-none-eabi/5.4.1/../../../arm-none-eabi/bin/ld: address 0x8010dd0 of blackmagic section `.text' is not within region `rom'
/usr/lib/gcc/arm-none-eabi/5.4.1/../../../arm-none-eabi/bin/ld: region `rom' overflowed by 3768 bytes
collect2: error: ld returned 1 exit status
Makefile:66: recipe for target 'blackmagic' failed
make: *** [blackmagic] Error 1
git remote add mubes https://github.com/mubes/blackmagic
git fetch mubes
git checkout -b bluepill mubes/bluepill
make clean
# gcc 5 generates too big binaries!
export PATH=/opt/DesignLab-1.0.8/hardware/tools/gcc-arm-none-eabi-4.8.3-2014q1/bin/:$PATH
make PROBE_HOST=bluepill
/nuc/stm32/stlink/build/Release/st-flash erase
/nuc/stm32/stlink/build/Release/st-flash write blackmagic_dfu.bin 0x8000000
/nuc/stm32/stlink/build/Release/st-flash write blackmagic.bin 0x8002000
# power cycle blue pill
dpavlin@nuc:/nuc/stm32/blackmagic/src$ dmesg | tail -8 | cut -c18-
usb 2-4.4: new full-speed USB device number 12 using xhci_hcd
usb 2-4.4: New USB device found, idVendor=1d50, idProduct=6018
usb 2-4.4: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 2-4.4: Product: Black Magic Probe (Bluepill), (Firmware v1.6-rc0-274-g39197b7)
usb 2-4.4: Manufacturer: Black Sphere Technologies
usb 2-4.4: SerialNumber: BED69CDC
cdc_acm 2-4.4:1.0: ttyACM0: USB ACM device
cdc_acm 2-4.4:1.2: ttyACM1: USB ACM device
.pre
^ st-link
https://github.com/texane/stlink
.pre
dpavlin@nuc:/nuc/stm32$ git clone https://github.com/texane/stlink
dpavlin@nuc:/nuc/stm32/stlink$ ./build/Release/st-info --probe
Found 1 stlink programmers
serial: 533f6a06483f55532144033f
openocd: "\x53\x3f\x6a\x06\x48\x3f\x55\x53\x21\x44\x03\x3f"
flash: 65536 (pagesize: 1024)
sram: 20480
chipid: 0x0410
descr: F1 Medium-density device
dpavlin@nuc:/nuc/stm32/stlink$
dpavlin@nuc:/nuc/stm32/stlink$ ./build/Release/st-flash erase
st-flash 1.3.1-14-geb03b7c
2017-04-07T17:37:27 INFO src/common.c: Loading device parameters....
2017-04-07T17:37:27 INFO src/common.c: Device connected is: F1 Medium-density device, id 0x20036410
2017-04-07T17:37:27 INFO src/common.c: SRAM size: 0x5000 bytes (20 KiB), Flash: 0x10000 bytes (64 KiB) in pages of 1024 bytes
Mass erasing
dpavlin@nuc:/nuc/stm32/blackmagic/src$ make HOST_PROBE=stlink
dpavlin@nuc:/nuc/stm32/blackmagic/src$ ../../stlink/build/Release/st-flash write blackmagic_dfu.bin 0x8000000
st-flash 1.3.1-14-geb03b7c
2017-04-07T17:41:59 INFO src/common.c: Loading device parameters....
2017-04-07T17:41:59 INFO src/common.c: Device connected is: F1 Medium-density device, id 0x20036410
2017-04-07T17:41:59 INFO src/common.c: SRAM size: 0x5000 bytes (20 KiB), Flash: 0x10000 bytes (64 KiB) in pages of 1024 bytes
2017-04-07T17:41:59 INFO src/common.c: Attempting to write 6780 (0x1a7c) bytes to stm32 address: 134217728 (0x8000000)
Flash page at addr: 0x08001800 erased
2017-04-07T17:41:59 INFO src/common.c: Finished erasing 7 pages of 1024 (0x400) bytes
2017-04-07T17:41:59 INFO src/common.c: Starting Flash write for VL/F0/F3 core id
2017-04-07T17:41:59 INFO src/flash_loader.c: Successfully loaded flash loader in sram
6/6 pages written
2017-04-07T17:41:59 INFO src/common.c: Starting verification of write complete
2017-04-07T17:41:59 INFO src/common.c: Flash written and verified! jolly good!
dpavlin@nuc:/nuc/stm32/blackmagic/src$ ../../stlink/build/Release/st-flash --reset --flash=128k write blackmagic.bin 0x8002000
st-flash 1.3.1-14-geb03b7c
2017-04-07T17:45:52 INFO src/common.c: Loading device parameters....
2017-04-07T17:45:52 INFO src/common.c: Device connected is: F1 Medium-density device, id 0x20036410
2017-04-07T17:45:52 INFO src/common.c: SRAM size: 0x5000 bytes (20 KiB), Flash: 0x10000 bytes (64 KiB) in pages of 1024 bytes
Forcing flash size: --flash=0x00020000
2017-04-07T17:45:52 INFO src/common.c: Attempting to write 77076 (0x12d14) bytes to stm32 address: 134225920 (0x8002000)
Flash page at addr: 0x08014c00 erased
2017-04-07T17:45:54 INFO src/common.c: Finished erasing 76 pages of 1024 (0x400) bytes
2017-04-07T17:45:54 INFO src/common.c: Starting Flash write for VL/F0/F3 core id
2017-04-07T17:45:54 INFO src/flash_loader.c: Successfully loaded flash loader in sram
75/75 pages written
2017-04-07T17:45:58 INFO src/common.c: Starting verification of write complete
2017-04-07T17:45:59 INFO src/common.c: Flash written and verified! jolly good!
.pre
this flash instructions doesn't work, recepie above for blue pill is more recent
Up: [Workspace Tour - Table of Contents]
Back: [What's the funny punctuation?]
Making links in Socialtext is very simple.
To add a link to a page in the workspace, first *double-click* to enter editing mode. Alternatively, click the *Edit* button.
Type the name of the page you want to link to, and turn it into a link simply by selecting it and clicking on http:base/images/wikiwyg_icons/link.gif in the toolbar.
If you make a link to a page that doesn't exist yet, your link will appear with a dotted underline. When you click on the link, the page will be created.
[How do I make a new page?]
Here are my notes about setup of various stuff on Eee PC to make it work better for me.
{toc: }
^ Startup
Edit `/usr/bin/startsimple.sh` and insert something along following lines before exec icewm
.pre
sudo rm /tmp/nologin
xrdb -merge ~/.Xresources
setxkbmap hr us
xterm &
exec icewm
.pre
^ Compressed root filesystem
I don't really care much about Xandos on my Eee PC. However, I really do like idea about having read-only system filesystem (especially if your startup scripts are breakable as easy as ones on eee are). So, to improve this idea, I started to think how to compress read-only partition so I can at least save space.
As a first experiment, I copied whole flash from eee (about 3.6Gb used) and compressed it using `gzip -1` (lowest possible compression level). I was quite amazed to see that resulting archive was only 1.3Gb. So, I was up to something (and additional 2Gb of free space on 4Gb eee is also nice :-)
^^ Update 2008-01-22
squashfs 3.3 can't compress comtent of eee's `/usr` without hanging on flock after about ~47000 files. This is quite annoying, but 3.2 works. Since it's compiled from upstream source it doesn't include lzma compression, but is saves 1.6Gb of disk space. "More details is available"<http://groups.google.com/group/eeepc-zagreb/browse_thread/thread/c68d220ec0c5b2dc>, but in Croatian only.
^^ Links
Here is collection of references about this issue:
{fetchrss: http://del.icio.us/rss/dpavlin/debian+usb full}
^ Disk images
^^ Backup image from Eee using external USB disk
.pre
dd if=/dev/sda of=/media/A/Partition1/flash4Gb.img
.pre
Path in `of` may be different depending on partition on your disk.
^^ Backup flash image from Eee PC using network
Transfer somehow whole disk image to other computer. Good way might be to use netcat with something like this:
* on Eee
.pre
sudo nc -l -p 8888 < /dev/sda
.pre
* on other computer
.pre
nc name.of.eee.pc 8888 > hda
.pre
You might want to insert compression if your network connection is slower than flash read speed (which is according to `hdparm -tT /dev/hda` around 21MB/sec).
Alternative is to take `P701L.gz` from DVD which came with machine, but it has only one partition which is factory default one.
^^ Backup just part of image
You can also copy just parts of flash filesystem if you want (this copies just disk after partition 2):
* on eee
.pre
dd if=/dev/sda bs=512 skip=4819500 | gzip | nc -w 3 other.computer
88882995524+0 records in
2995524+0 records out
1533708288 bytes (1.5 GB) copied, 279.348 seconds, 5.5 MB/s
.pre
* on other computer
.pre
nc -l -p 8888 | gzip -cd | > /rest/tmp/hda2-4
.pre
* now, ectract beginning of disk and first partition from P701L
.pre
dd if=P701L of=hda1 bs=512 count=4819500
.pre
* and merge partition together to create full disk image
.pre
cat hda1 hda2-4 > hda
.pre
^ Emulation
How to create virtual Eee PC?
^^ Example flash image
.pre
# fdisk -l hda
Disk /backup/eee/hda: 3 GB, 3997486080 bytes
255 heads, 63 sectors/track, 486 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/backup/eee/hda1 1 300 2409718 83 Linux
/backup/eee/hda2 301 484 1469947 83 Linux
/backup/eee/hda3 485 485 0 c FAT32 LBA
/backup/eee/hda4 486 486 0 ef EFI FAT
.pre
^^ Mount file-system
We need first file system (factory defaults) to get access to kernel and initrd image
.pre
# fdisk -u -l hda
Disk /backup/eee/hda: 3 GB, 3997486080 bytes
255 heads, 63 sectors/track, 486 cylinders, total 7807590 sectors
Units = sectors of 1 * 512 = 512 bytes
Device Boot Start End Blocks Id System
/backup/eee/hda1 63 4803435 2409718 83 Linux
/backup/eee/hda2 4819563 7759395 1469947 83 Linux
/backup/eee/hda3 7775523 7775460 0 c FAT32 LBA
/backup/eee/hda4 7791588 7791525 0 ef EFI FAT
# mkdir 1
# mount hda 1 -o loop,offset=`expr 63 \* 512`
.pre
^^ Start emulation
.pre
qemu -m 512 -hda hda -kernel boot/vmlinuz-2.6.21.4-eeepc -initrd boot/initramfs-eeepc.img -append "rw root=/dev/sda1"
.pre
^ Links
{fetchrss: http://del.icio.us/rss/dpavlin/eeepc full}
^ Speed, hardware crypto
* http://lwn.net/Articles/269075/
Welcome to my new unsorted stuff site. If you are here to "learn about rot13"<http://en.wikipedia.org/wiki/ROT13> this might not be the right place.
If you are, however looking latest and/or unsorted snippets which didn't made to "my homepage"<http://www.rot13.org/~dpavlin/> or "blog"<http://blog.rot13.org/> you might be on right place.
Recent changes are best way to get a hang of what's going on.
| {search: category: projects} | {search: category: howto} |
{fetchrss: http://blog.rot13.org/index.xml}