|
|
CIFXNode Class ReferenceInheritance diagram for CIFXNode:
List of all members.
|
Public Member Functions |
| virtual const IFXGUID & | GetCID () |
| IFXRESULT IFXAPI | SetSceneGraph (IFXSceneGraph *pInSceneGraph) |
| IFXRESULT IFXAPI | Mark (void) |
| void IFXAPI | SetPriority (U32 uInPriority, BOOL bRecursive, BOOL bPromotionOnly) |
| virtual IFXRESULT IFXAPI | Update (IFXSubject *pInSubject, U32 inChangeBits, IFXREFIID rIType) |
| IFXRESULT IFXAPI | InitializeCollection (IFXSpatial **pInSpatials=NULL, U32 inNumberOfSpatials=0, IFXSpatial::eType eInType=IFXSpatial::UNSPECIFIED) |
| IFXRESULT IFXAPI | InitializeCollection (IFXCollection *pInCollection) |
| IFXRESULT IFXAPI | AddSpatials (IFXSpatial **pInSpatials, U32 inNumberOfSpatials, IFXSpatial::eType eInType=IFXSpatial::UNSPECIFIED) |
| IFXRESULT IFXAPI | RemoveSpatials (IFXSpatial **pInSpatials, U32 inNumberOfSpatials, IFXSpatial::eType eInType=IFXSpatial::UNSPECIFIED) |
| IFXRESULT IFXAPI | GetSpatials (IFXSpatial **&rpOutSpatials, U32 &rOutNumberOfSpatials, IFXSpatial::eType eInType) |
| IFXRESULT IFXAPI | Notify (IFXModifierMessage eInMessage, void *pMessageContext) |
| IFXRESULT IFXAPI | ApplyTransformToNode (IFXMatrix4x4 *pPinF, U32 parent) |
| IFXRESULT IFXAPI | GetCollection (IFXREFCID rInCID, IFXCollection **ppOutCollection) |
| U32 IFXAPI | GetDebugFlags (void) |
| void IFXAPI | SetDebugFlags (U32 uIn) |
| IFXRESULT IFXAPI | GetSubgraphBound (IFXVector4 &rSphere, U32 rootInstance) |
| const IFXMatrix4x4 &IFXAPI | GetMatrix (U32 index) const |
| U32 IFXAPI | GetNumberOfChildren (const BOOL bInDeepCount=FALSE) |
| IFXNode *IFXAPI | GetChildNR (const U32 childIndex) |
| IFXRESULT IFXAPI | AddChild (IFXNode *pChildNode) |
| IFXRESULT IFXAPI | RemoveChild (IFXNode *pChildNode) |
| IFXRESULT IFXAPI | RemoveChild (const U32 index) |
| IFXRESULT IFXAPI | GetWorldMatrix (U32 Index, IFXMatrix4x4 **ppWorldMatrix) |
| IFXRESULT IFXAPI | GetWorldMatrices (IFXArray< IFXMatrix4x4 > **ppWorldMatrices) |
| IFXRESULT IFXAPI | MarkMotions () |
| IFXRESULT IFXAPI | Pick (U32 myInstance, IFXVector3 &position, IFXVector3 &direction, IFXSimpleList **ppPickedObjectList) |
| IFXRESULT IFXAPI | SetMatrix (U32 Index, IFXMatrix4x4 *pMatrix) |
| IFXRESULT IFXAPI | InvalidateMatrix () |
| IFXRESULT IFXAPI | AddParent (IFXNode *pParentNode) |
| IFXRESULT IFXAPI | RemoveParent (const U32 index) |
| U32 IFXAPI | GetNumberOfParents () |
| IFXRESULT IFXAPI | GetNumberOfInstances (U32 *numInstances) |
| IFXNode *IFXAPI | GetParentNR (const U32 parentIndex) |
| IFXRESULT IFXAPI | Prune () |
| void IFXAPI | PreDestruct () |
Protected Member Functions |
| | CIFXNode () |
| virtual | ~CIFXNode () |
| IFXRESULT IFXAPI | GenerateOutput (U32 inOutputDataElementIndex, void *&rpOutData, BOOL &rNeedRelease) |
| IFXRESULT IFXAPI | SetDataPacket (IFXModifierDataPacket *pInInputDataPacket, IFXModifierDataPacket *pInDataPacket) |
| | IFXDECLAREMEMBER (IFXSimpleList, m_pPickObjectList) |
Protected Attributes |
| U32 | m_uRefCount |
| IFXCollection ** | m_pCollections |
| U32 | m_uCollections |
| U32 | m_uCollectionsAllocated |
| IFXArray< IFXParent > | m_Parents |
| IFXArray< IFXMatrix4x4 > | m_Local |
| IFXArray< IFXMatrix4x4 > | m_World |
| IFXArray< IFXNode * > | m_pChildren |
| U32 | m_debugFlags |
| U32 | m_uMyDataPacketTransformAspectBit |
| U32 | m_uMyDataPacketTransformIndex |
| IFXSubject * | m_pMyDataPacketAsSubjectNR |
| IFXObserver * | m_pMyIFXObserverNR |
Private Member Functions |
| IFXRESULT | AttachToParentsWorldTransform (U32 parentIndex) |
| BOOL | IsThisNode (IFXNode *pParentNode, IFXNode *pThisNode) |
Static Private Member Functions |
| static BOOL | HasParent (IFXNode *pMyNode, U32 uMyInstance, IFXNode *pParentNode, U32 uParentInstance=0xFFFFFFFF) |
Private Attributes |
| IFXNode * | m_pMyIFXNodeNR |
| IFXSubject * | m_pSceneGraphSubjectNR |
Classes |
| struct | IFXParent |
Constructor & Destructor Documentation
| CIFXNode::CIFXNode |
( |
|
) |
[protected] |
|
| CIFXNode::~CIFXNode |
( |
|
) |
[protected, virtual] |
|
Member Function Documentation
| IFXRESULT CIFXNode::AddChild |
( |
IFXNode * |
pChildNode |
) |
[virtual] |
|
|
|
Add child to parent.
- Parameters:
-
| IFXNode* | pChildNode - Node to add it as child to the m_pChildren array |
- Returns:
- IFXRESULT
- Note:
- Node->AddRef
Implements IFXNode. |
| IFXRESULT CIFXNode::AddParent |
( |
IFXNode * |
pNewParentNode |
) |
[virtual] |
|
|
|
Add parent to child.
- Parameters:
-
| IFXNode* | pNewParentNode - parent to add it |
- Returns:
- IFXRESULT
- Note:
- fucntion adds parent to IFXParent array. In case if this Node wasn't already parented by pNewParentNode it is adding to m_pChildren array. Spatial setting.
Implements IFXNode. |
|
|
Adds the given spatials from the collection.
- Parameters:
-
| pInSpatials | The list of spatials to add to the collection. |
| uInNumberOfSpatials | The number of spatials in the list. |
| eInType | If this parameter is provided, the type of ALL of the provided spatials is assumed to be eInType. If not specified, each spatial is queryied for it's type separately. |
- Returns:
- One of the following IFXRESULT codes:
- IFX_OK
No error.
- IFX_E_OUT_OF_MEMORY
Not enough memory was available to initialize.
Implements IFXCollection. |
| IFXRESULT CIFXNode::ApplyTransformToNode |
( |
IFXMatrix4x4 * |
pPinF, |
|
|
U32 |
parent |
|
) |
[virtual] |
|
|
|
Transform hierarchy control.
Implements IFXNode. |
| IFXRESULT CIFXNode::AttachToParentsWorldTransform |
( |
U32 |
parentIndex |
) |
[private] |
|
| IFXRESULT CIFXNode::GenerateOutput |
( |
U32 |
inOutputDataElementIndex, |
|
|
void *& |
rpOutData, |
|
|
BOOL & |
rNeedRelease |
|
) |
[protected, virtual] |
|
|
|
Generate a result from the input DataPacket.
- Parameters:
-
| inDataElementIndex | The index of the DataElement. |
| rpOutData | The pointer to the output DataElement interface. |
- Returns:
- Upon success, IFX_OK is returned or IFX_W_MODIFIER_OUTPUT_NOT_CHANGED if the specified output DataElement did not change. Otherwise, one of the following failures are returned: IFX_E_INVALID_ENTRY if the specified DataElement does not exist; or IFX_E_NOT_INITIALIZED if the Modifier, ModifierDataPacket, and/or the ModifierChain was not initialized properly.
Implements CIFXModifier.
Reimplemented in CIFXGroup, CIFXLight, CIFXModel, and CIFXView. |
| IFXNode * CIFXNode::GetChildNR |
( |
const U32 |
childIndex |
) |
[virtual] |
|
|
|
Get child by index.
- Parameters:
-
| const | U32 ChildIndex - index of required child |
- Returns:
- IFXNode* ppChildNode - result value
- Note:
- no references
Implements IFXNode. |
| virtual const IFXGUID& CIFXNode::GetCID |
( |
|
) |
[inline, virtual] |
|
|
|
Subgraph lists.
Implements IFXNode. |
| U32 IFXAPI CIFXNode::GetDebugFlags |
( |
void |
|
) |
[inline, virtual] |
|
|
|
Debug mode control.
Implements IFXNode. |
|
|
Transform hierarchy control.
Implements IFXNode. |
| U32 CIFXNode::GetNumberOfChildren |
( |
const BOOL |
bInDeepCount = FALSE |
) |
[virtual] |
|
|
|
Number of parent's children.
- Parameters:
-
| BOOL | bInDeepCount - flag to switch method of Number of children calculation. |
| U32* | puOutCount - return value. |
- Returns:
- IFXRESULT.
- Note:
- with bInDeepCount == FALSE function doesn't return real number of children. if child is parented by one parent more than one times it stored in m_pChildren array only once.
Implements IFXNode. |
| IFXRESULT CIFXNode::GetNumberOfInstances |
( |
U32 * |
pOutCount |
) |
[virtual] |
|
|
|
number of Node's instances.
- Parameters:
-
| U32* | puOutCount - return value |
- Returns:
- IFXRESULT
Implements IFXNode. |
| U32 CIFXNode::GetNumberOfParents |
( |
|
) |
[virtual] |
|
|
|
get number of parents.
- Returns:
- U32 - real number of parents even if child more than one time is parented by one of the parent
Implements IFXNode. |
| IFXNode * CIFXNode::GetParentNR |
( |
const U32 |
ParentIndex |
) |
[virtual] |
|
|
|
get parent by index
- Parameters:
-
| const | U32 ParentIndex - index of element in parent's array |
- Returns:
- IFXNode* - required parent node
- Note:
- no references
Implements IFXNode. |
|
|
Returns a reference to the spatials, of the given type, within the collection.
- Parameters:
-
| eInType | The type of spatials to be returned from the collection. |
| rpOutSpatials | The address of the list of resultant spatials. |
| ruOutNumberOfSpatials | The number of resultant spatials. |
| eInType | If this parameter is provided, rpOutSpatials will contain only spatials of type specified. |
- Returns:
- One of the following IFXRESULT codes:
Implements IFXCollection. |
| IFXRESULT CIFXNode::GetSubgraphBound |
( |
IFXVector4 & |
rSphere, |
|
|
U32 |
rootInstance |
|
) |
[virtual] |
|
| IFXRESULT CIFXNode::GetWorldMatrix |
( |
U32 |
Index, |
|
|
IFXMatrix4x4 ** |
ppWorldMatrix |
|
) |
[virtual] |
|
|
|
Returns the current world matrix from the node's dataPacket.
Implements IFXNode. |
| BOOL CIFXNode::HasParent |
( |
IFXNode * |
pMyNode, |
|
|
U32 |
uMyInstance, |
|
|
IFXNode * |
pParentNode, |
|
|
U32 |
uParentInstance = 0xFFFFFFFF |
|
) |
[static, private] |
|
| CIFXNode::IFXDECLAREMEMBER |
( |
IFXSimpleList |
, |
|
|
m_pPickObjectList |
|
|
) |
[protected] |
|
| IFXRESULT CIFXNode::InitializeCollection |
( |
IFXCollection * |
pInCollection |
) |
[virtual] |
|
|
|
Initializes the Collection.
- Precondition:
- None; re-initialization is supported.
- Postcondition:
- If a spatial set is provided, the collection will contain these spatials, if not, it will be empty.
- Parameters:
-
| rpInSpatials | A reference to the address of the array of spatials to add to the collection. |
| uInNumberOfSpatials | The number of spatials in the rpInSpatial array. |
| eInType | If this parameter is provided, the type of ALL of the provided spatials is assumed to be eInType. If not specified, each spatial is queryied for it's type separately. |
- Returns:
- One of the following IFXRESULT codes:
- IFX_OK
No error.
- IFX_E_OUT_OF_MEMORY
Not enough memory was available to initialize.
Implements IFXCollection. |
| IFXRESULT CIFXNode::InitializeCollection |
( |
IFXSpatial ** |
pInSpatials = NULL , |
|
|
U32 |
inNumberOfSpatials = 0 , |
|
|
IFXSpatial::eType |
eInType = IFXSpatial::UNSPECIFIED |
|
) |
[virtual] |
|
| IFXRESULT CIFXNode::InvalidateMatrix |
( |
|
) |
[virtual] |
|
|
|
Transform hierarchy control.
Implements IFXNode. |
| BOOL CIFXNode::IsThisNode |
( |
IFXNode * |
pParentNode, |
|
|
IFXNode * |
pThisNode |
|
) |
[private] |
|
|
|
helper function to check the parent/children tree to know if the Node already parent of given one
- Parameters:
-
| IFXNode* | pParentNode - Node to find |
- Returns:
- BOOL - result of operation. TRUE - Node was found in the tree
|
| IFXRESULT CIFXNode::Mark |
( |
void |
|
) |
[virtual] |
|
|
|
Recursively marks a subset of the database.
Reimplemented from CIFXMarker.
Reimplemented in CIFXModel. |
| IFXRESULT CIFXNode::MarkMotions |
( |
|
) |
[virtual] |
|
|
|
Motion Marking.
Implements IFXNode. |
| IFXRESULT CIFXNode::Notify |
( |
IFXModifierMessage |
eInMessage, |
|
|
void * |
pMessageContext |
|
) |
[virtual] |
|
| void CIFXNode::PreDestruct |
( |
|
) |
[virtual] |
|
| IFXRESULT CIFXNode::Prune |
( |
|
) |
[virtual] |
|
| IFXRESULT CIFXNode::RemoveChild |
( |
const U32 |
index |
) |
[virtual] |
|
|
|
remove child by index
- Note:
- Node->Release
Implements IFXNode. |
| IFXRESULT CIFXNode::RemoveChild |
( |
IFXNode * |
pChildNode |
) |
[virtual] |
|
|
|
Remove child.
- Parameters:
-
| IFXNode* | pChildNode - requested child |
- Returns:
- IFXRESULT
- Note:
- Node->Release fuction looks for requested Node and removes it from m_pChildren array
Implements IFXNode. |
| IFXRESULT CIFXNode::RemoveParent |
( |
const U32 |
index |
) |
[virtual] |
|
|
|
Remove existing parent completely.
All links of given parent with children will be cutted.
- Parameters:
-
| U32 | Index Index of parent which should be removed from the list. |
- Returns:
- IFXRESULT
Implements IFXNode. |
| IFXRESULT CIFXNode::RemoveSpatials |
( |
IFXSpatial ** |
pInSpatials, |
|
|
U32 |
inNumberOfSpatials, |
|
|
IFXSpatial::eType |
eInType = IFXSpatial::UNSPECIFIED |
|
) |
[virtual] |
|
|
|
Removes the given spatials from the collection.
- Parameters:
-
| pInSpatials | An array of IFXSpatial pointers that refer to the spatials to remove from the collection. |
| uInNumberOfSpatials | The number of spatials in the list. |
| eInType | If this parameter is provided, the type of ALL of the provided spatials is assumed to be eInType. If not specified, each spatial is queryied for it's type separately. |
- Returns:
- One of the following IFXRESULT codes:
- IFX_OK
No error.
- IFX_E_NOT_FOUND
One or more of the provided spatials was not found in the collection.
Implements IFXCollection. |
|
|
Associates a new DataPacket with the Modifier.
- Precondition:
- None.
- Postcondition:
- The provided DataPacket is associated with the Modifier. If the Modifier was already associated with a DataPacket, it is first released.
- Parameters:
-
| pInDataPacket | The incoming IFXDataPacket That will provide input to the modifier chain. |
| pInDataPacket | The incoming IFXDataPacket to be associated with the Modifier. |
- Returns:
- Upon success, IFX_OK is returned. Otherwise, one of the following failures are returned: IFX_E_OUT_OF_MEMORY.
Implements CIFXModifier.
Reimplemented in CIFXGroup, CIFXLight, CIFXModel, and CIFXView. |
| void IFXAPI CIFXNode::SetDebugFlags |
( |
U32 |
uIn |
) |
[inline, virtual] |
|
|
|
Debug mode control.
Implements IFXNode. |
| IFXRESULT CIFXNode::SetMatrix |
( |
U32 |
Index, |
|
|
IFXMatrix4x4 * |
pMatrix |
|
) |
[virtual] |
|
|
|
Transform hierarchy control.
Implements IFXNode. |
| void CIFXNode::SetPriority |
( |
U32 |
uInPriority, |
|
|
BOOL |
bRecursive, |
|
|
BOOL |
bPromotionOnly |
|
) |
[virtual] |
|
|
|
Set the streaming priority ( zero = initial load segment ) The two default, optional arguments are used in the following way:
- by default, bRecursive == TRUE, indicating that components should propagate the SetPriority() call to any subordinate (child) components.
If bRecursive == FALSE, the SetPriority() only applies to the component upon which the method was called (i.e. local only).
- by default, bPromotionOnly == TRUE, indicating that the specified priority (uInPriority) is only applied if it is a greater priority (lower U32) than the current priority of the component. In other words, by default, you cannot lower a components priority. If bPromotionOnly == FALSE, then the component accepts the new priority irregardless of its value relative to its old priority.
Reimplemented from CIFXMarker.
Reimplemented in CIFXModel. |
| IFXRESULT CIFXNode::SetSceneGraph |
( |
IFXSceneGraph * |
pInSceneGraph |
) |
[virtual] |
|
|
|
Notification that the provided subject has changed.
- Parameters:
-
| pInSubject | A pointer to the IFXSubject interface of the component that changed. |
| uInChangeBits | The aspects of interest that changed as defined by the supplied IFXSubject's published interest bits. if uInChangeBits are 0, then the subject is shutting down, and should be released if AddRef'ed, or local references should be cleared in the weak reference case. |
- Returns:
- One of the following IFXRESULT codes:
- IFX_OK
No error.
- IFX_E_INVALID_POINTER
pInSubject was NULL.
- IFX_E_OUT_OF_MEMORY
Not enough memory is available to resolve the change.
- Note:
- This method is typically called from IFXSubject::PostChanges().
This method with uInChangeBits = 0 allows for the circular reference between the Observer and the Subject to be broken.
Implements IFXObserver.
Reimplemented in CIFXModel, and CIFXView. |
Member Data Documentation
© 1999 - 2006 Intel Corporation. All rights reserved.
* Other names and brands may be claimed as the property of others.
|
|


New to Mac? How to use the built-in Mac Help system
by Sandy WrittenhouseWhen you’re getting familiar with your new Mac, there are times when even simple things can be hard to figure out. And you may not have the time to search the web for an answer. Luckily, macOS comes with a built-in Help feature that works really well.
Whether you want more details on how to use a feature or help finding a menu option, Mac’s Help system is there. We’ll show you how to access Help, what you can do with it, and some tips for using it.
The built-in Mac Help system
- Opening Help on Mac
- Using Help in the menu bar
- Using the Help window toolbar
- Clicking links within Help
Opening Help on Mac
When you have Finder open, you can access the Help system from your menu bar, all the way to the right. If you have an app open, the Help button in the menu bar will take you to the help topics specific to that app instead.
You can also access Help for certain sections in your System Preferences. If there is help available, you’ll see a question mark in the lower right corner of the window. The topics you see when you click the button will relate to the specific section you’re viewing.
For instance, if you open System Preferences, select Mouse, and choose Point & Click, when you click the question mark, the Help topics you see are for that exact area of Point & Click for your Mouse.
Using Help in the menu bar
Obviously, when you click Help from the menu bar, you can pop in a search term. You also have the option to open macOS Help, if you prefer. But most times, using a keyword to search for what you need will get you the results you seek. Just click when you see what you need and the Help window will open.
If the item you’re searching for is an option within the menu, you’ll see this and exactly where it resides when move your cursor over the item.
Using the Help window toolbar
When you have the Help window open, whether you open it with the button in the menu bar or question mark in System Preferences, you have some additional options.
In the Help window toolbar at the top, from left to right, you have arrows you can use to go back to the previous page or forward again.
Next, you have a Table of Contents button. This is super handy for seeing an outline related to your search so you can jump to different areas if needed.
If you’d like to share something from the Help section, the next button gives you your default sharing options. So if you’re helping out a friend or family member, you can share the Help topic with them.
Finally, you have a search box. If you want to look for something completely different or try to narrow down your search, just pop a word or phrase into the box and you’ll see suggestions.
Clicking links within Help
You’ll notice as you’re using the Help system that some words or phrases are linked (blue). And where you are directed when you click a link may change.
Some links have a dotted underline. Those will show you a preview of what the word or phrase is referring to.
Other links will take you to another section of the Help system if there is a topic dedicated to it.
And still other links will open things for you such as the settings in System Preferences.
So, pay attention to those linked words and phrases for additional help within the Help system.
Wrapping it up
The built-in Help system on macOS is there for you when you need it. It offers a ton of information about most anything you need on your Mac. And if you’re a new Mac user, it’s a great tool to keep in mind when you need a little help.
Have you checked out the Help system on your Mac yet and if so, has it answered your questions? Let us know your thoughts on the feature in the comments below!
For related articles for new Mac users, check out how to use tags with files and folders or organize your desktop more efficiently.


Readme File¶
Gym Electric Motor¶
The gym-electric-motor package is a software toolbox for the simulation of different electric motors. The toolbox is built upon the OpenAI Gym Environments for reinforcement learning. Therefore, the toolbox is especially designed for running reinforcement learning algorithms to train agents to control electric motors. So far, several DC-motor models and a permanent magnet synchronous motor (PMSM) are available. Beside electrical motors, also converters and load models are implemented. The converters can be driven by means of a duty cycle (continuous mode) or switching commands (discrete mode). The figure shows the basic scheme of the converter, motor and load.
Physical Structure of the Environments Components¶
Control Flow of a Step Cycle of the Environment¶
Installing¶
- Install gym-electric-motor from PyPI (recommended):
pip install gym-electric-motor
- Install from Github source:
git clone git@github.com:upb-lea/gym-electric-motor.git
cd gym-electric-motor
# Then either
python setup.py install
# or alternatively
pip install -e .
Authors¶
Arne Traue, Gerrit Book
Important notes¶
Latest readme update: 01-10-2019
Getting started¶
Like every gym environment, the basic user interface consists of four main functions.
gym.make(environment-id, **kwargs)
- Returns an instantiated motor environment. Call this function at the beginning.
env.reset()
- Resets the motor. This includes a new initial state and new reference trajectories. Call this function before a new episode starts.
env.step(action)
- Simulate one single time step on the motor with an action. Call this function iteratively until termination is reached.
env.render()
- Update the visualization of the motor states.
Gym Make Call¶
The make function takes the environment-ids and several constructor arguments. With the environment-id you select a certain motor type and action type (continuous or discrete) and with the further constructor arguments you can parametrize the environment to your control problem.
'emotor-dc-extex-cont-v0'
- externally excited DC motor with continuous actions.
'emotor-dc-extex-disc-v0'
- externally excited DC motor with discrete actions.
'emotor-dc-permex-cont-v0'
- permanently excited DC motor with continuous actions.
'emotor-dc-permex-disc-v0'
- permanently excited DC motor with discrete actions.
'emotor-dc-shunt-cont-v0'
- DC shunt motor with continuous actions.
'emotor-dc-shunt-disc-v0'
- DC shunt motor with discrete actions.
'emotor-dc-series-cont-v0'
- DC series motor with continuous actions.
'emotor-dc-series-disc-v0'
- DC series motor with discrete actions.
'emotor-pmsm-cont-v0'
:- permanent magnet synchronous motor with continuous actions.
'emotor-pmsm-disc-v0'
:- permanent magnet synchronous motor with discrete actions.
With the constructor arguments you can parametrize the control problem. You can select, which motor model to take, which quantities to control, etc. For further information have a look at [Link for the APIDOC Base Env Site]
Reset¶
The reset function determines new references, new initial values and resets the visualization. Call this function before a new episode begins. The parameters of the motor, converter and load will be those during instantiation.
Step¶
This function performs one action on the environment for one time step. It simulates the motor and needs to be called in every time step. It takes the action as parameter only. First the input voltage to the motor from the converter is determined and afterwards an integrator is used to compute the next state. Eventually, the reward is evaluated and returned together with the next observation and a flag indicating termination. Several reward functions are available.
Render¶
The visualization contains graphs of the motor quantities ‘speed, voltages, currents, torque’ for one episode. What should be shown is to be specified in the configuration-parameter. The quantities that should be displayed can be specified in the constructor-parameters. All visualizations are optional and recommended to be disabled for increased speed of training.
Examples¶
- Conventional PI controller as speed controller on a dc series motor (jump to source).
- Training and testing of a Keras-rl DDPG-Agent as a speed controller on a dc series motor (jump to source).
Motor Models¶
The following motor models are included:
Four DC motors:
- permanently excited motor
- externally excited motor
- series motor
- shunt motor
and the PMSM (permanent magnet synchronous motor)
Converter¶
Following converters are included:
- 1 quadrant converter (1QC)
- 2 quadrant converter (2QC) as an asymmetric half bridge with both current polarities
- 4 quadrant converter (4QC)
All converters can consider interlocking times and a dead time of one sampling interval. Furthermore, they can be controlled with a discrete action space or a continuous action space.
Discrete actions are the direct switching states of the transistors. Continuous actions are the duty cycles for a pulse width modulation on the transistors.
Load¶
The load model consists of a quadratic load function, with user defined coefficients. Furthermore the moment of inertia of the load attached to the motor can be specified.
Notes about the Parameters¶
All nominal values of voltages and currents are DC values in the case of a DC motor and peak phase values for the PMSM. Therefore, data sheet values for line voltage and phase currents of a PMSM has to be transformed with:
Furthermore, the angular velocity is the mechanical one and not the electrical:


I²C lets you vastly extend the Pi's capabilities, by connecting a variety of other devices. Examples include temperature sensors, LCD displays and Analogue to Digital Converters.
The first tutorial, Using I2C On The Raspberry Pi, explains how to configure the hardware and software of the Pi to get I²C up and running. If you already know what you want to do with I²C, then this is an ideal place to start.
You may find that some or all of the devices you want to connect use a different voltage for communication than the Pi (so called logic levels.) In this case, first build a bidirectional level shifter to convert the voltages, which is described in the second tutorial.
If you're stuck for ideas, then why not read about using I²C to interconnect Arduinos with the Raspberry Pi? This gives you the variety of low-level I/O options and dedicated processing of a microcontroller, coupled with all the flexibility and processing speed of the Raspberry Pi.
Not only can you communicate with other devices using I²C, it's also possible to turn them on and off with a simple circuit, described in the fourth tutorial. For example, this could be used to turn devices off when not in use, saving power.


ndt_gslam
1.0
Main Page
Namespaces
Classes
Files
Class List
Class Index
Class Hierarchy
Class Members
Class Hierarchy
Go to the textual class hierarchy
Generated by
1.8.11


This is on a little bit of a personal note as well but I thought that it would be worth sharing. Right now is the beginning of the fall time and this is the time when people are beginning to go back to school and start up class again. Now, I am currently out of school and working so this does not really affect me nearly as much as I am currently working but the timeline naturally fits to create some fall goals for myself.
Whether you are in school or out of school, as a developer, it is a great idea to create term goals for yourself to help you accomplish things you seek to complete. This is also a very important thing if you want to become a Technical Director, Artist, etc.
One thing that I have learned being out of school and being in the work force for a little over a year, is that your “school” work doesn’t prove to the companies out there that you are a competent worker and can fulfill yourself. These are done through your personal projects and most of the efforts that you perform outside of school.
As a technical director, the companies that I applied for were not asking me about my grades and what I learned in school. They asked about some of the projects that I have worked on that involved communicating with a team and the roles that we played to create an effective environment for accomplishing a task.
Now, this isn’t to say that this can come from school as well. When I interview with Rhythm & Hues for an opportunity as a pipeline technical director, my projects from my Scientific Visualization class really shined as much of it was python based and showed them that I can create tools to visualize data. I was lucky enough to find a class where the professor gave us the freedom to create our own projects and own research to receive a grade.
One thing I want to point out, is to not just do things for the grade. The grade only lasts for the semester and won’t take you much further. The content, however, will take you much further. If you are in a computer science class learning python and algorithms, why not take what you learn and create your own projects that visualize the algorithms?
In turn, take some time to create a fall goal list that does not pertain directly to school work. Look at your classes and try to look at how you can apply those into your personal projects. If you are taking a programming languages course, why not create a lexical analyzer to analyze a toy language?
If you have any questions, follow and ping me on Twitter- I’m twitter.


Welcome to the Student Meme Generator, a service targeted to Aalto University students. Feel free to create or explore funny meme pictures!


| Modifier and Type | Method and Description |
|---|---|
static WebClientUrlCollection |
WebClientUrlCollection.loadFromXml(EwsXmlReader reader)
Loads instance of WebClientUrlCollection from XML.
|
static AlternateMailboxCollection |
AlternateMailboxCollection.loadFromXml(EwsXmlReader reader)
Loads instance of AlternateMailboxCollection from XML.
|
protected static WebClientUrl |
WebClientUrl.loadFromXml(EwsXmlReader reader)
Loads WebClientUrl instance from XML.
|
protected static ProtocolConnection |
ProtocolConnection.loadFromXml(EwsXmlReader reader)
Read user setting with ProtocolConnection value.
|
static AlternateMailbox |
AlternateMailbox.loadFromXml(EwsXmlReader reader)
PLoads AlternateMailbox instance from XML.
|
static ProtocolConnectionCollection |
ProtocolConnectionCollection.LoadFromXml(EwsXmlReader reader)
Read user setting with ProtocolConnectionCollection value.
|
void |
AutodiscoverResponseCollection.loadFromXml(EwsXmlReader reader,
String endElementName)
Loads response from XML.
|
| Modifier and Type | Method and Description |
|---|---|
void |
ConfigurationSettingsBase.loadFromXml(EwsXmlReader reader)
Loads the settings from XML.
|
boolean |
ConfigurationSettingsBase.tryReadCurrentXmlElement(EwsXmlReader reader)
Tries to read the current XML element.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
OutlookUser.loadFromXml(EwsXmlReader reader)
Load from XML.
|
protected void |
OutlookProtocol.loadFromXml(EwsXmlReader reader)
Parses the XML using the specified reader and creates an Outlook
protocol.
|
protected void |
OutlookAccount.loadFromXml(EwsXmlReader reader)
Parses the specified reader.
|
boolean |
OutlookConfigurationSettings.tryReadCurrentXmlElement(EwsXmlReader reader)
Tries to read the current XML element.
|
| Modifier and Type | Method and Description |
|---|---|
void |
UserSettingError.loadFromXml(EwsXmlReader reader)
Loads from XML.
|
void |
DomainSettingError.loadFromXml(EwsXmlReader reader)
Loads from XML.
|
static AutodiscoverError |
AutodiscoverError.parse(EwsXmlReader reader)
Parses the XML through the specified reader and creates an Autodiscover
error.
|
| Modifier and Type | Method and Description |
|---|---|
protected AutodiscoverResponse |
AutodiscoverRequest.loadFromXml(EwsXmlReader reader)
Loads response from XML.
|
protected AutodiscoverResponse |
AutodiscoverRequest.readSoapBody(EwsXmlReader reader)
Read SOAP body.
|
protected void |
GetUserSettingsRequest.readSoapHeader(EwsXmlReader reader)
Read the partner token soap header.
|
protected void |
AutodiscoverRequest.readSoapHeader(EwsXmlReader reader)
Reads a single SOAP header.
|
protected void |
AutodiscoverRequest.readSoapHeaders(EwsXmlReader reader)
Read SOAP header.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
GetDomainSettingsResponse.loadDomainSettingsFromXml(EwsXmlReader reader)
Loads from XML.
|
void |
GetUserSettingsResponse.loadFromXml(EwsXmlReader reader,
String endElementName)
Loads response from XML.
|
void |
GetDomainSettingsResponse.loadFromXml(EwsXmlReader reader,
String endElementName)
Loads response from XML.
|
void |
AutodiscoverResponse.loadFromXml(EwsXmlReader reader,
String endElementName)
Initializes a new instance of the AutodiscoverResponse class.
|
protected void |
GetUserSettingsResponse.loadUserSettingsFromXml(EwsXmlReader reader)
Loads from XML.
|
| Modifier and Type | Class and Description |
|---|---|
class |
EwsServiceMultiResponseXmlReader
Represents an xml reader used by the ExchangeService to parse multi-response streams,
such as GetStreamingEvents.
|
class |
EwsServiceXmlReader
XML reader.
|
| Modifier and Type | Field and Description |
|---|---|
(package private) EwsXmlReader |
EwsXmlReaderTest.impl |
| Modifier and Type | Method and Description |
|---|---|
static SoapFaultDetails |
SoapFaultDetails.parse(EwsXmlReader reader,
XmlNamespace soapNamespace)
Parses the.
|


Food for Thought
Things I learnt
1. Why does my site look different across browsers?
One of the frustrations I faced early on was cross-browser consistency
How I overcome it
Tools that help with testing
2. How am I supposed to remember everything?
“Never memorize something that you can look up.”
― Albert Einstein
Its impossible to remember every class, function, and element. The more sites I build the more I am able to recall the most used classes. For everything else have easy access to reference sites, books, cheat sheets, QA forums to get help when I need it.
3. How to make my website more appealing?
the aesthetics
Currently, I am using the website design from Bedimcode.
Here are some pointers I keep in check:


The Earth Cafe is a quaint bohemian-style coffee house.
Inside, you’ll find mismatching wallpaper, chairs and tables that placidly come together for a nice colorful mix. It's a place where you can get music, art, express yourself, make a difference in the world, and various other takeaways, depending on how you make use of the space but most of all, be a part of the community.
- We use a reverse osmosis system to filter our water!
- We make our own Almond and Coconut milks without artificial additives!
- We have natural sweeteners such as Agave, Honey & Raw Sugar.
- We serve ORGANIC, GLUTEN-FREE & VEGAN OPTIONS!


The simple class
Posted 3 April, 2019- About 5 mins to read
I work in many legacy code bases, and in fact, I’ve made it a big part of my career. I love diving into big monoliths that have grown out of proportion and tidying them up. One of the best parts of that work is rewriting a God class into a collection of small reusable classes. Let’s take a look at what makes a simple class great.
One of my favourite types of classes is a value object. For those not in the known, a value object is a small class that holds a value with a tiny bit of extra logic surrounding it. Sounds simple enough right? I think a nice way of looking at these classes is implementing them as an extension of the type system of your programming language. Let take a look at an uncomplicated example.
<?php
declare(strict_types=1);
final class CustomerName
{
private $firstName;
private $lastName;
public function __construct(string $firstName, string $lastName)
{
$this->firstName = $firstName;
$this->lastName = $lastName;
}
public function firstName(): string
{
return $this->firstName;
}
public function lastName(): string
{
return $this->lastName;
}
public function fullName(): string
{
return sprintf(
'%s %s',
$this->firstName(),
$this->lastName()
);
}
}
This small class doesn’t do anything really, and it just holds two strings. The only tiny bit of function (on first glance) is that it concatenates the two strings. However, for the minimal amount of code in this class, it does offer a ton of value to your code base.
Putting an end to the class struggle
Once we start replacing every occurrence of the first name and last name with this simple class, you will quickly begin to see the value. First of all, every time you come across this class in your code, you know that it has a first name and a last name in it. You also know that both of these values will be strings. And that you have an easy way to display the first name - last name combination.
You can now also add this as a safety in your new classes. You could, for example, do something like this:
<?php
public function sendMail(
CustomerName $customerName,
Email $email
): void
{
$mail = new Mail($customerName->fullName(), $email);
// send mail
}
Here you easily guard your method from all kinds of extra logic. You know that the variables that enter the method are of the type Email and Customer class.
There is however still a major issue with our values objects. We could still trick our system into accepting empty strings. Let’s take a look at how we can make these classes just a tiny bit more robust.
Putting a stop to empty values
We know that our values in our object will always be of the type string, but “” is also a string. so you could do
new CustomerName('', '');
or even new CustomerName('\$', '!');
You could allow that last one if you are building a platform for rappers, but in most cases, you would want to guard against that.
If you are using PHP (like the examples are), I would suggest using a package like webmozart/assert.
<?php
public function __construct(string $firstName, string $lastName)
{
Assert::stringNotEmpty($firstName);
Assert::stringNotEmpty($lastName);
Assert::alpha($firstName);
Assert::alpha($lastName);
$this->firstName = $firstName;
$this->lastName = $lastName;
}
(you could add a private validation method to the class that is called on the first line of the constructor if there are many validation rules)
The class is now a lot smarter; it validates the values that come in and will throw an exception when they don’t meet the expectations of the class.
Now you can be sure that whenever you encounter this class, the values within will be usable.
Adding more means of production to the classes
It might be very tempting to start now adding more and more logic to these classes. However, I would caution restraint here.
A common thing you see is people adding getters and setters to these classes. You might notice we already have getters (we just not named them getters), and I would strongly recommend against adding setters.
If you need to update a value in the class, create a new instance of the class. Value objects are meant to be built and discarded. By creating new value objects you also make sure you pass the constructor every time, and therefore including the validation.
If you really feel like adding setters, make sure they create new instances themselves:
<?php
public function setFirstName(string $firstName): CustomerName
{
return new self($firstName, $this->lastName());
}
Another thing to touch upon is named constructors. A named constructor allows you to create the value object under different circumstances. I feel like it is easiest to explain with another example.
<?php
declare(strict_types=1);
final class CustomerName
{
private $firstName;
private $lastName;
public function __construct(string $firstName, string $lastName)
{
Assert::stringNotEmpty($firstName);
Assert::stringNotEmpty($lastName);
Assert::alpha($firstName);
Assert::alpha($lastName);
$this->firstName = $firstName;
$this->lastName = $lastName;
}
public static function fromFullName(string $fullname): self
{
$pieces = explode(' ', $fullname);
return new CustomerName($pieces[0], $pieces[1]);
}
}
(this example is to demonstrate the function of a named constructor. This method assumes that a name is always in 2 pieces with the first name as the first piece. If you want to implement this, please add extra logic)
These constructors are a small convenient way to create the value object. Named constructors allow for great flexibility. However, like always, you should not take this flexibility too far.
You should always ask yourself, is this method solving a real problem, or am I just adding this for a one-off small convenience?
Named constructors are very useful in a “Time” class, where you can create the class from a string format, or from the hour, minute and second parameters as further explained here by Mathias Verraes.
In closing
There is still a lot to be said about value objects. We haven’t touched upon testing, logging, naming…
For more information about these topics, I would advise you to look into some DDD books or even better check out Matthias Noback’s book “Style Guide for Object Design”. A book that prompted me to write this article. (I get no personal benefits for advertising this book, I just think it’s a great book)
If you haven’t implemented Value objects into your codebase, I would greatly advise you to give it a try. You will wonder how you ever lived without it.


Whenever you open a new tab, the new tab page will be a page that tells a corny joke. Uses Official Joke API to pull a random joke onto the webpage by JavaScript. Click here for more details.
A simple game that keeps track of how fast you click the button in 10 seconds. Uses Mongoose, MongoDB, and Node.js in order to save highscores across all browsers. Click here for more details.


Class APPLESync
- java.lang.Object
-
- org.lwjgl.opengles.APPLESync
-
public class APPLESync extends java.lang.Object
Native bindings to the APPLE_sync extension.This extension introduces the concept of "sync objects". Sync objects are a synchronization primitive - a representation of events whose completion status can be tested or waited upon. One specific type of sync object, the "fence sync object", is supported in this extension, and additional types can easily be added in the future.
Fence sync objects have corresponding fences, which are inserted into the OpenGL command stream at the time the sync object is created. A sync object can be queried for a given condition. The only condition supported for fence sync objects is completion of the corresponding fence command. Fence completion allows applications to request a partial Finish, wherein all commands prior to the fence will be forced to complete before control is returned to the calling process.
These new mechanisms allow for synchronization between the host CPU and the GPU, which may be accessing the same resources (typically memory), as well as between multiple GL contexts bound to multiple threads in the host CPU.
Requires
GLES 2.0
.
-
-
Field Summary
Fields Modifier and Type Field and Description static int
GL_ALREADY_SIGNALED_APPLE
GL_CONDITION_SATISFIED_APPLEReturned by ClientWaitSyncAPPLE.static int
GL_MAX_SERVER_WAIT_TIMEOUT_APPLE
Accepted as thepname
parameter of GetInteger64vAPPLE.static int
GL_OBJECT_TYPE_APPLE
Accepted as thepname
parameter of GetSyncivAPPLE.static int
GL_SIGNALED_APPLE
Returned invalues
for GetSyncivAPPLEpname
SYNC_STATUS_APPLE.static int
GL_SYNC_CONDITION_APPLE
Accepted as thepname
parameter of GetSyncivAPPLE.static int
GL_SYNC_FENCE_APPLE
Returned invalues
for GetSyncivpname
OBJECT_TYPE_APPLE.static int
GL_SYNC_FLAGS_APPLE
Accepted as thepname
parameter of GetSyncivAPPLE.static int
GL_SYNC_FLUSH_COMMANDS_BIT_APPLE
Accepted in theflags
parameter of ClientWaitSyncAPPLE.static int
GL_SYNC_GPU_COMMANDS_COMPLETE_APPLE
Returned invalues
for GetSyncivAPPLEpname
SYNC_CONDITION_APPLE.static int
GL_SYNC_OBJECT_APPLE
Accepted by thetype
parameter of LabelObjectEXT and GetObjectLabelEXT.static int
GL_SYNC_STATUS_APPLE
Accepted as thepname
parameter of GetSyncivAPPLE.static int
GL_TIMEOUT_EXPIRED_APPLE
Returned by ClientWaitSyncAPPLE.static long
GL_TIMEOUT_IGNORED_APPLE
Accepted in thetimeout
parameter of WaitSyncAPPLE.static int
GL_UNSIGNALED_APPLE
Returned invalues
for GetSyncivAPPLEpname
SYNC_STATUS_APPLE.static int
GL_WAIT_FAILED_APPLE
Returned by ClientWaitSyncAPPLE.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method and Description static int
glClientWaitSyncAPPLE(long sync, int flags, long timeout)
static void
glDeleteSyncAPPLE(long sync)
static long
glFenceSyncAPPLE(int condition, int flags)
static long
glGetInteger64APPLE(int pname)
static void
glGetInteger64vAPPLE(int pname, long[] params)
Array version of:GetInteger64vAPPLE
static void
glGetInteger64vAPPLE(int pname, java.nio.LongBuffer params)
static int
glGetSynciAPPLE(long sync, int pname, java.nio.IntBuffer length)
static void
glGetSyncivAPPLE(long sync, int pname, int[] length, int[] values)
Array version of:GetSyncivAPPLE
static void
glGetSyncivAPPLE(long sync, int pname, java.nio.IntBuffer length, java.nio.IntBuffer values)
static boolean
glIsSyncAPPLE(long sync)
static void
glWaitSyncAPPLE(long sync, int flags, long timeout)
-
-
-
Field Detail
-
GL_MAX_SERVER_WAIT_TIMEOUT_APPLE
public static final int GL_MAX_SERVER_WAIT_TIMEOUT_APPLE
Accepted as thepname
parameter of GetInteger64vAPPLE.- See Also:
- Constant Field Values
-
GL_OBJECT_TYPE_APPLE
public static final int GL_OBJECT_TYPE_APPLE
Accepted as thepname
parameter of GetSyncivAPPLE.- See Also:
- Constant Field Values
-
GL_SYNC_CONDITION_APPLE
public static final int GL_SYNC_CONDITION_APPLE
Accepted as thepname
parameter of GetSyncivAPPLE.- See Also:
- Constant Field Values
-
GL_SYNC_STATUS_APPLE
public static final int GL_SYNC_STATUS_APPLE
Accepted as thepname
parameter of GetSyncivAPPLE.- See Also:
- Constant Field Values
-
GL_SYNC_FLAGS_APPLE
public static final int GL_SYNC_FLAGS_APPLE
Accepted as thepname
parameter of GetSyncivAPPLE.- See Also:
- Constant Field Values
-
GL_SYNC_FENCE_APPLE
public static final int GL_SYNC_FENCE_APPLE
Returned invalues
for GetSyncivpname
OBJECT_TYPE_APPLE.- See Also:
- Constant Field Values
-
GL_SYNC_GPU_COMMANDS_COMPLETE_APPLE
public static final int GL_SYNC_GPU_COMMANDS_COMPLETE_APPLE
Returned invalues
for GetSyncivAPPLEpname
SYNC_CONDITION_APPLE.- See Also:
- Constant Field Values
-
GL_UNSIGNALED_APPLE
public static final int GL_UNSIGNALED_APPLE
Returned invalues
for GetSyncivAPPLEpname
SYNC_STATUS_APPLE.- See Also:
- Constant Field Values
-
GL_SIGNALED_APPLE
public static final int GL_SIGNALED_APPLE
Returned invalues
for GetSyncivAPPLEpname
SYNC_STATUS_APPLE.- See Also:
- Constant Field Values
-
GL_SYNC_FLUSH_COMMANDS_BIT_APPLE
public static final int GL_SYNC_FLUSH_COMMANDS_BIT_APPLE
Accepted in theflags
parameter of ClientWaitSyncAPPLE.- See Also:
- Constant Field Values
-
GL_TIMEOUT_IGNORED_APPLE
public static final long GL_TIMEOUT_IGNORED_APPLE
Accepted in thetimeout
parameter of WaitSyncAPPLE.- See Also:
- Constant Field Values
-
GL_ALREADY_SIGNALED_APPLE
public static final int GL_ALREADY_SIGNALED_APPLE
Returned by ClientWaitSyncAPPLE.- See Also:
- Constant Field Values
-
GL_TIMEOUT_EXPIRED_APPLE
public static final int GL_TIMEOUT_EXPIRED_APPLE
Returned by ClientWaitSyncAPPLE.- See Also:
- Constant Field Values
-
GL_CONDITION_SATISFIED_APPLE
public static final int GL_CONDITION_SATISFIED_APPLE
Returned by ClientWaitSyncAPPLE.- See Also:
- Constant Field Values
-
GL_WAIT_FAILED_APPLE
public static final int GL_WAIT_FAILED_APPLE
Returned by ClientWaitSyncAPPLE.- See Also:
- Constant Field Values
-
GL_SYNC_OBJECT_APPLE
public static final int GL_SYNC_OBJECT_APPLE
Accepted by thetype
parameter of LabelObjectEXT and GetObjectLabelEXT.- See Also:
- Constant Field Values
-
-
Method Detail
-
glFenceSyncAPPLE
public static long glFenceSyncAPPLE(int condition, int flags)
-
glIsSyncAPPLE
public static boolean glIsSyncAPPLE(long sync)
-
glDeleteSyncAPPLE
public static void glDeleteSyncAPPLE(long sync)
-
glClientWaitSyncAPPLE
public static int glClientWaitSyncAPPLE(long sync, int flags, long timeout)
-
glWaitSyncAPPLE
public static void glWaitSyncAPPLE(long sync, int flags, long timeout)
-
glGetInteger64vAPPLE
public static void glGetInteger64vAPPLE(int pname, java.nio.LongBuffer params)
-
glGetInteger64APPLE
public static long glGetInteger64APPLE(int pname)
-
glGetSyncivAPPLE
public static void glGetSyncivAPPLE(long sync, int pname, java.nio.IntBuffer length, java.nio.IntBuffer values)
-
glGetSynciAPPLE
public static int glGetSynciAPPLE(long sync, int pname, java.nio.IntBuffer length)
-
glGetInteger64vAPPLE
public static void glGetInteger64vAPPLE(int pname, long[] params)
Array version of:GetInteger64vAPPLE
-
glGetSyncivAPPLE
public static void glGetSyncivAPPLE(long sync, int pname, int[] length, int[] values)
Array version of:GetSyncivAPPLE
-
-


When you work with us, you are part of a team of commited collaborators. All aspects of our software development process are integrated, interactive and agile.
Our approach unifies design, development and product management to create exceptional products.
We start each project by understanding your business goals, the user's needs and product requirements
Then we help translate them into effective and elegant solutions.
Before we sign or write a line of code our team will spend necessary time needed to understand your product vision.
The outcome of this scoping session are proposal or high-level statement of work
based on your requirements, we can provide acomplete offering or just the pieces you need
Our design practice offers a full range of services including brand strategy, interaction and visual design and user experience testing.
Throughout your project, our designers create and implement visual design and workflows, solicit user feedback and work with you to make sure what gets built is what is needed.
All engineers are fluent in the latest enterprise, mobile and web development technologies.
They collaborate with your team to write, and improve code on a daily basis, using proven practices such as test-driven development and pair programming.
Planning and development is iterative. Because we are constantly coding and testing, the products we build are always ready to go live.
This iterative process allows for changes as business requirements evolve.


WHO AM I?
An Android & Front-End Web Developer and Digital Marketer based in Nairobi, passionately dedicated to building creative, optimized and high performance applications. Hailing from a marketing background, I believe that development is not just about coding, it’s also about creating an awesome user experience. With a fair understanding of today's market requirements, I approach projects strategically to provide the desired solutions
WHAT HAVE I DONE?
Quotes
Angular 8
A website where users can create quotes, view them, upvote and downvote the quotes and get to see the highest voted quotes
View siteBroken Bad
Android
An android app that helps in keeping track of Breaking Bad characters; their nicknames,real world name, birthday, if they ended up deceased or alive and the seasons that they were involved in.
View repositoryVirtual Noticeboard
Angular 8 / Java Spark
A website in form of a bulletin board with sticky notes in which users can post and view information that is relevant to them within an institution
View repositoryMy Restaurants
Android
I consumed the Yelp v3 API to create a mobile application where a user can list all restaurants, their yelp ratings and food they serve in a specific area by inputting a zipcode for the area they want to look up
View repositoryNews Portal API
Java Spark
A REST API for querying and retrieving scoped news and information.
View repositoryGitSearch
Angular 8
I consumed the Github API to clone the version control where a user can get all my repositories and information as well as search for any github user or repository
View siteCaesar Cipher
Java Spark
This is a command line application that encrypts messages in that each letter in the message is shifted a certain number of places down the alphabet. For example, with a shift of 1, A would be replaced by B, B would become C, and so on
View repository


Lorem ipsum dolor sit amet, consectetur adipiscing elit. Eu ut ac dolor sit amet,
Variable Speed Drive (VSD) AK06 series is designed to control and protect electric submersible and surface ...
Read more
30 / 04 / 2020
350 views
All news
Sort by blogger Show all
-
About blogger
Variable Speed Drive (VSD) AK06 series is designed
-
About blogger
Variable Speed Drive (VSD) AK06 series is designed to control and protect electric submersible and surface pumps with induction
-
About blogger
Variable Speed Drive (VSD) AK06 series is designed to control and protect electric submersible and surface pumps with induction
-
About blogger
Variable Speed Drive (VSD) AK06 series is designed to control and protect electric submersible and surface pumps with induction
-
About blogger
Variable Speed Drive (VSD) AK06 series is designed to control and protect electric submersible and surface pumps with induction


{% extends "main/base.html" %}
{% block title %}Welcome to whatever this is{% endblock title %}
{% block todo %}
- Info goes here for how to use
- Links to upload, registration, login etc - still need permissions everywhere
-
{% endblock todo %}
{% block content %}


Trademark registration is the answer. Like a name is the unique identification for a person, trade mark is a unique identity given to a particular product or service which distinguish it from the products or services of similar category. It can be in the form of logo, brand, tag line or it can be a combination of name and logo both. It can also be obtained for a Business name, distinctive catch phrases, taglines or captions. The registration of trademark is governed by The Trade Marks Act 1999. A trademark registration is an immediate process which is done online and the trademark is ready to be used within hours. However it is very important that the trademark should not be similar to an existing trade mark or should not be specifically prohibited by law.
Food license in India is mandatory for the entities involved in activities related to manufacturing, processing, packaging, storage, transportation, distribution of food, import and includes food services, catering services, sale of food or food ingredients etc. The validity of a Food License prolongs from 1 to 5 years and depends upon the number of years that is chosen by the food operator. There are three categories of food license, Basic registration , state food license and central food license. The administrator of fssai is Ministry of health and family welfare The main objective of fssai as a regulatory body is to lay down standards for food products, to regulate
By company registration here means Formation of a company in India, setting up subsidiaries or branch office in India. A private limited company in India is a separate legal entity. Shareholders are therefore not personally liable for the debt of the company. Minimum requirement for any person to form a private limited company is that two directors of which one shall be person resident in India. Therefore even for a foreign national can be a director in a private limited company in India. You must also know that once you form a private limited company, It is mandatory for you to appoint auditor of the company within 30 days of incorporation and there are annual compliance like filing your financial statement and Annual Return to the registrar. Read our Article on compliance by company to know due dates of filing.
IEC registration is required by a person for exporting or importing goods. It is a 10 digit code which is issued by the Directorate General of Foreign Trade (DGFT). All businesses which are engaged in Import and Export of goods require registering Import Export Code. IE code has lifetime validity. Importers are not allowed to proceed without this code and exporters can’t take benefit of exports from DGFT, customs, Export Promotion Council, if they don’t have this code.
For any LLP one of the mandatory compliance under company law is filing statements of accounts and annual return with Ministry of corporate affairs every year. The partners of LLP are responsible for filing annual return of LLP every year. The team of CA/CS here will solely take care of your LLP compliance. The due date of filing statements of accounts is 30th May of each year and due date of filing annual return is 30th October of each year. Noncompliance with the LLP annual filing means you will face the penalty of Rs.100 each day of default.
Book keeping is crucial to your businesses. Your compliance, your filings - everything will be accurate if you have a best book keeping system. You could always hire someone to write down your inflows and outflows, However there is no assurance on correctness of the book unless the person maintaining book is professional. By preparing your accounts, we will help you make a plan and structured file. Our team of experts will maintain the records of your business. You can plan your expenses and financial decisions accordingly. Your business decisions will be better if you rely on our team of experts. Our team will manage your accounts which includes preparing your cash flow, computing your profitability, performance ratios, Debtor/creditor management, customer activity, credit control and budget comparisons.
It is a tax levied by the Government of India on the income of every person. The provisions governing the Income-tax are covered in the Income-tax Act, 1961. Income-tax is levied on the annual income of a person. The year under the Income-tax Law is the period starting from 1st April and ending on 31st March of next calendar year. Our expert team of chartered Accountant can help you file Income Tax return for any type of Income you have. Even if someone is not liable to file ITR, it is always a wise decision to file one because of advantages such as Availing of home loan, car loan, it serves as a legal documents at many places such as visa authorities, financial institutions etc.
A Digital Signature Certificate (DSC) is a secure digital key that certifies the identity of the holder, issued by a Certifying Authority (CA). It typically contains your identity (name, email, country, APNIC account name and your public key). Digital Certificates use Public Key Infrastructure meaning data that has been digitally signed or encrypted by a private key can only be decrypted by its corresponding public key. A digital certificate is an electronic "credit card" that establishes your credentials when doing business or other transactions on the Web.
To provide the benefit of tax deducted to the person receiving the payment, it is mandatory to file a TDS return by the deductor. Each deductor has to issue certificate stating the amount paid and how much TDS has been deducted on same. Deductor has to mandatorily file TDS return every quarter. The deductee can claim this TDS deducted as tax paid by him for the financial year in which TDS has been deducted. Regarding rates and section one has to go as per what income tax law says. We are experts in filing TDS return in India. We can even guide you or your accountant the provisions of TDS.
Even the all-powerful Pointing has no control about the blind texts it is an almost unorthographic life One day however a small line of blind text by the name of Lorem Ipsum decided to leave for the far World of Grammar.
Even the all-powerful Pointing has no control about the blind texts it is an almost unorthographic life One day however a small line of blind text by the name of Lorem Ipsum decided to leave for the far World of Grammar.
Even the all-powerful Pointing has no control about the blind texts it is an almost unorthographic life One day however a small line of blind text by the name of Lorem Ipsum decided to leave for the far World of Grammar.
— Mani Kumar K V(Tech Lead)
A small river named Duden flows by their place and supplies it with the necessary regelialia. It is a paradisematic country, in which roasted parts of sentences fly into your mouth.
— Yamini (Software Engineer)
Even the all-powerful Pointing has no control about the blind texts it is an almost unorthographic life One day however a small line of blind text by the name of Lorem Ipsum decided to leave for the far World of Grammar.
— Rajesh Sinha (Industrialist)
And if she hasn’t been rewritten, then they are still using her.
— Kip Hugh
A small river named Duden flows by their place and supplies it with the necessary regelialia. It is a paradisematic country, in which roasted parts of sentences fly into your mouth.
— James Robertson
Even the all-powerful Pointing has no control about the blind texts it is an almost unorthographic life One day however a small line of blind text by the name of Lorem Ipsum decided to leave for the far World of Grammar.
— Ben Goodrich


Peak-a-boo
Can I please just peak?
If I run a test to
visitors,
and I look at my results every
visitors,
Even though I am targeting a 5% error rate,
My chance of a false positive is actually ____ .
Explanation of what's going on + links to learn more + link to download code from github


Go-Torch
Hi! My name is Ben Sandler and this is my beloved go-torch! It is a stochastic flame profiler written in Go. Attach an image file and go-torch will stochastically (i.e. random) profile it! Curious if your image is a torch or not? If it is, is the torch cool or is it lame? Go-torch will help you find out once and for all!


Code Survey
by Grant Eadie
Find out your coding future with this short survey.
Input your
name
here:
Are you planning on working in
web development?
Yes
No
Do you see yourself designing applications for
hardware?
Yes
No
Will you be working with
data
frequently?
Yes
No
Is your dream to make apps for
iOS or macOS
Yes
No
Are you willing to learn a
difficult
but versitile language?
Yes
No
Submit
Hello
,
Learn more here:
Best of luck!


{% extends "base.html" %} {% block title %}Ticket holder area{% endblock %} {% block content %}
We will be expanding this area with a lot of nice functions leading up to the conference. We are kicking off with the most important functions:


|
TouchGFX
v4.13.0
|
An icon button style. More...
#include <touchgfx/containers/buttons/IconButtonStyle.hpp>
Public Member Functions | |
| IconButtonStyle () | |
| Default constructor. | |
| virtual | ~IconButtonStyle () |
| Destructor. | |
| virtual void | setIconBitmaps (const Bitmap &newIconReleased, const Bitmap &newIconPressed) |
| Sets icon bitmaps. More... | |
| void | setIconX (int16_t x) |
| Sets icon x coordinate. More... | |
| void | setIconY (int16_t y) |
| Sets icon y coordinate. More... | |
| void | setIconXY (int16_t x, int16_t y) |
| Sets icon xy. More... | |
| Bitmap | getCurrentlyDisplayedIcon () const |
| Gets currently displayed icon. More... | |
| int16_t | getIconX () const |
| Gets icon x coordinate. More... | |
| int16_t | getIconY () const |
| Gets icon y coordinate. More... | |
Protected Member Functions | |
| virtual void | handlePressedUpdated () |
| Handles the pressed updated. | |
| virtual void | handleAlphaUpdated () |
| Handles the alpha updated. | |
Protected Attributes | |
| Bitmap | iconReleased |
| Icon to display when button is not pressed. | |
| Bitmap | iconPressed |
| Icon to display when button is pressed. | |
| Image | iconImage |
| The icon image. | |
An icon button style. This class is supposed to be used with one of the ButtonTrigger classes to create a functional button. This class will show one of two icons depending on the state of the button (pressed or released).
To get a background behind the icon, use IconButtonStyle together with e.g. ImageButtonStyle: IconButtonStyle<ImageButtonStyle<ClickButtonTrigger> > myButton;
The IconButtonStyle will center the icon on the enclosing container (normally AbstractButtonContainer). Set the size of the button before setting the icons.
The position of the icon can be adjusted with setIconXY.
| T | Generic type parameter. Typically a AbstractButtonContainer subclass. |


A Soldier's Story
A Soldier's Story is a movie starring Howard E. Rollins Jr., Adolph Caesar, and Art Evans. An African American officer investigates a murder in a racially charged situation in World War II.


| # | Scenario | Fails (of 2) | Status |
|---|---|---|---|
| 1 | 1 link | 0 | SUCCESS |
| 2 | 1 loop | 0 | SUCCESS |
| 3 | 4 subnetworks, looped and tree; Root 1-1 | 0 | SUCCESS |
| 4 | 4 subnetworks, looped and tree; Root 1-2 | 0 | SUCCESS |
| 5 | 4 subnetworks, looped and tree; Root 2-3 | 0 | SUCCESS |
| 6 | 4 subnetworks, looped and tree; Root 3-4 | 0 | SUCCESS |


{% extends 'base.html' %} {% block content %}
Student number: {{ id }}
Address: {{ address }}
Return to the list to select a different student.


| Element |
Failures |
ID: 977410
Name: Curtain Wall Mullions : Rectangular Mullion : 64 x 128 rectangular |
Element is a duplicate at the same location and base level. |
ID: 976939
Name: Curtain Wall Mullions : Rectangular Mullion : 64 x 128 rectangular |
Element is a duplicate at the same location and base level. |
ID: 697577
Name: Furniture Systems : hood enclosure : hood enclosure |
There are in-place families in the model and linked models. |
ID: 506168
Name: Furniture Systems : wardrobe1 : wardrobe |
There are in-place families in the model and linked models. |
ID: 523531
Name: Furniture Systems : wardrobe2 : wardrobe |
There are in-place families in the model and linked models. |
ID: 694796
Name: Generic Models : Miele Built-under Dishwasher G 4101 U CS : Miele Built-under Dishwasher G 4101 U CS |
There are generic model families in the model and linked models. |
ID: 680539
Name: Generic Models : Miele Induction Cooktop KM 6350 LPT : Miele Induction Cooktop 6350 LPT |
There are generic model families in the model and linked models. |
ID: 674370
Name: Generic Models : Miele Washing Machine W 5820 WPS : Miele Washing Machine W 5820 WPS |
There are generic model families in the model and linked models. |
ID: 499496
Name: Generic Models : Walvit_Hung Bowl_604118 W : Walvit |
There are generic model families in the model and linked models. |
ID: 938761
Name: Generic Models : Walvit_Hung Bowl_604118 W : Walvit |
There are generic model families in the model and linked models. |
ID: 935747
Name: Generic Models : Walvit_Hung Bowl_604118 W : Walvit |
There are generic model families in the model and linked models. |
ID: 937571
Name: Generic Models : Walvit_Hung Bowl_604118 W : Walvit |
There are generic model families in the model and linked models. |
ID: 997119
Name: Generic Models : Water Glass : Water Glass |
There are generic model families in the model and linked models. |
ID: 997115
Name: Generic Models : Water Glass : Water Glass |
There are generic model families in the model and linked models. |
ID: 997117
Name: Generic Models : Water Glass : Water Glass |
There are generic model families in the model and linked models. |
ID: 997069
Name: Generic Models : Water Glass : Water Glass |
There are generic model families in the model and linked models. |
ID: 997051
Name: Generic Models : Water Glass : Water Glass |
There are generic model families in the model and linked models. |
ID: 996881
Name: Generic Models : Water Glass : Water Glass |
There are generic model families in the model and linked models. |
ID: 997121
Name: Generic Models : Water Glass : Water Glass |
There are generic model families in the model and linked models. |
ID: 997033
Name: Generic Models : Water Glass : Water Glass |
There are generic model families in the model and linked models. |
ID: 997120
Name: Generic Models : White Porcelain Plate : Fine China - Plate |
There are generic model families in the model and linked models. |
ID: 997118
Name: Generic Models : White Porcelain Plate : Fine China - Plate |
There are generic model families in the model and linked models. |
ID: 997050
Name: Generic Models : White Porcelain Plate : Fine China - Plate |
There are generic model families in the model and linked models. |
ID: 997032
Name: Generic Models : White Porcelain Plate : Fine China - Plate |
There are generic model families in the model and linked models. |
ID: 994782
Name: Generic Models : White Porcelain Plate : Fine China - Plate |
There are generic model families in the model and linked models. |
ID: 997116
Name: Generic Models : White Porcelain Plate : Fine China - Plate |
There are generic model families in the model and linked models. |
ID: 997114
Name: Generic Models : White Porcelain Plate : Fine China - Plate |
There are generic model families in the model and linked models. |
ID: 997068
Name: Generic Models : White Porcelain Plate : Fine China - Plate |
There are generic model families in the model and linked models. |
ID: 993980
Name: Generic Models : aalto vase - tall : White |
There are generic model families in the model and linked models. |
ID: 701300
Name: Generic Models : fire place hang : fire place hang |
There are generic model families in the model and linked models. |
ID: 628359
Name: Mass : water : water |
There are in-place families in the model and linked models. There are mass elements in the model and linked models. |
ID: 800382
Name: Model Groups : Array Group 1 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800213
Name: Model Groups : Array Group 1 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800384
Name: Model Groups : Array Group 1 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800392
Name: Model Groups : Array Group 1 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800390
Name: Model Groups : Array Group 1 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800281
Name: Model Groups : Array Group 1 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800326
Name: Model Groups : Array Group 1 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800330
Name: Model Groups : Array Group 1 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800341
Name: Model Groups : Array Group 1 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800351
Name: Model Groups : Array Group 1 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800349
Name: Model Groups : Array Group 1 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800343
Name: Model Groups : Array Group 1 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800352
Name: Model Groups : Array Group 2 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800393
Name: Model Groups : Array Group 2 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 800331
Name: Model Groups : Array Group 2 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 988384
Name: Model Groups : Array Group 3 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 988397
Name: Model Groups : Array Group 3 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 988460
Name: Model Groups : Array Group 3 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 988641
Name: Model Groups : Array Group 4 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 988604
Name: Model Groups : Array Group 4 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |
ID: 988591
Name: Model Groups : Array Group 4 |
There are groups in the model and linked models. All groups shall be ungrouped for final submittals. |


Coming together is a beginning. Keeping together is a progress. Dancing together is success.Group dances have always been a sight to see. Here many teams compete to step up and become the conquering cadre.
Dance first. Think later. It’s the natural order.Dance, the art of moving your body with finesse. It’s a solo dancing competition where you rise above the rest how to sway with the beat.
Why walk when you can dance? Dream with your feet and let your twinning moves grant you redemption. A dance competition where you and your partner can shimmy together and win the hearts of the crowd.


Contains several useful navigation helper functions, including easily building folder paths, quick viewing dataframes in 'Excel', creating date vectors and changing the console prompt to reflect time.
| Version: | <IP_ADDRESS> |
| Depends: | R (≥ 3.2.1) |
| Imports: | tidyverse, zoo, utils, xts, magrittr, purrr, readr |
| Suggests: | knitr, rmarkdown |
| Published: | 2017-10-16 |
| Author: | Nico Katzke [aut, cre] |
| Maintainer: | Nico Katzke <nfkatzke at gmail.com> |
| License: | GPL-3 |
| NeedsCompilation: | yes |
| Materials: | README |
| CRAN checks: | rmsfuns results |
| Reference manual: | rmsfuns.pdf |
| Vignettes: |
rmsfuns |
| Package source: | rmsfuns_<IP_ADDRESS>.tar.gz |
| Windows binaries: | r-devel: rmsfuns_<IP_ADDRESS>.zip, r-release: rmsfuns_<IP_ADDRESS>.zip, r-oldrel: rmsfuns_<IP_ADDRESS>.zip |
| OS X binaries: | r-release: rmsfuns_<IP_ADDRESS>.tgz, r-oldrel: rmsfuns_<IP_ADDRESS>.tgz |
| Old sources: | rmsfuns archive |
Please use the canonical form https://CRAN.R-project.org/package=rmsfuns to link to this page.


Problem Statement
- You need to make a battery powered launching device(Fire gun).
- You also need to convert a simple plastic bottle into a rocket which can be fired through
- the gun into the sky reaching weapon of mass destruction.
Working Principle
For Rocket:
The plastic bottle is filled with alcohol vapour and secured on the Fire gun. It blasts off as
soon as an electric spark is produced by Fire gun.
( Cheat Codes : For better control of the range of rocket, the concepts of Centre of Mass
-Centre of Pressure should be applied while making the rocket. )
For Fire gun:
It should look like a gun made of anything like plastic. It should have long nozzle
approximately 1 feet (0.30m) (for safety purpose). As soon as you plug the trigger of the
gun, the spark is generated inside the bottle which is fitted on the nozzle of the gun. This
will lead to blast off the rocket.
For any help refer to the link: https://www.youtube.com/watch?v=wuz0curb_hg
Rules
- A team can have at most 2 members.
- Each team needs to bring a modified bottle rocket and Fire gun with them. The alcohol will
be provided.
- Inner diameter of mouth of the bottle should be slightly greater than the nozzle.
Judging Criteria
Judging will be based on the followings:
- Each team must submit about 100 words text explaining their Fire gun and rocket design.
- You can also add the image of your rocket .The last date for submission is 21 October by
5 pm. Send your responses in a MS Word file at<EMAIL_ADDRESS>(10 points)
- The appearance of gun and rocket . (10 points each)
- The rockets will be shot and the range will be measured .The range will be measured for
only those rockets whose range exceeds a minimum distance, provided at the beginning
of this round. The rocket having the maximum range will be the winner. (70 points)


这篇文章主要聚焦于debian系统，其他的linux发行版的用法应该是一致的。
Setup
You start by installing the needed tools, So, on my debian:
sudo apt-get install libvirt-dev virtinst libvirt-daemon libvirt-daemon-system
如果没有找到相应的软件包，你可以尝试一下apt-cache
命令。
(If you cant found these softwares, you can try it : apt-cache)
系统提示你缺少什么软件就安装什么软件。
sudo apt-cache search libvirt
你还可以使用通配符进行模糊查找。 (You can fuzzy search with wildcard)
Then you got a libvirtd
process running on your machine:
yubo@debian:~/git$ sudo ps u -C libvirtd
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
root 4470 1.4 0.7<PHONE_NUMBER>2 ? Ssl 20:38 0:00 /usr/sbin/libvi
The role of libvirtd
is quite important. It takes care of managing the VMSrunning on your host.You can control it with command virsh
.
First few steps with libvirt
Before anything else, you should know that libvirt and virsh
not only allow you to control VMs running on your own system, but can control VMs running on the remote systems or a cluster of physical machines. Every time you use virsh
, With qemu,you need type it looks like:
qemu://xxx/system
qemu://xxx/session
I will introduce more details about virsh in another post,now i am focus on the libvirt-vms.
Managing system VMS
Here, libvirtd
is listening the command send to /var/run/libvirt
,so you may add a credential user for libvirt, and you have opportunity to write socket, which needs a user to belong to the libvirt
group.
If you edit /etc/libvirt/libvirtd.conf
, you can configure libvirt to wait for a commands using a variety of different mechanisms, including for example SSL encrypted TCP sockets.
yubo@debian:~/git$ sudo usermod -a -G libvirt yubo
Add my user name into libvirt group.
Defining a network
yubo@debian:~/git$ virsh -c qemu:///system net-list
Name State Autostart Persistent
----------------------------------------------------------
This means that there are no active virtual networks, Try one more time adding --all
:
yubo@debian:~/git$ virsh -c qemu:///system net-list --all
Name State Autostart Persistent
----------------------------------------------------------
default inactive no yes
note
Now your network’s is default
.
And notice the default network, If you want to inspect or change the configure file of the network, you can use either net-dumpxml
or net-edit
h -c qemu:///system net-dumpxml default
<network>
<name>default</name>
<uuid>e46e2c1b-5263-4428-b8fc-bfa4805a2ebc</uuid>
<forward mode='nat'/>
<bridge name='virbr0' stp='on' delay='0'/>
<mac address='52:54:00:34:36:d3'/>
<ip address='<IP_ADDRESS>' netmask='<IP_ADDRESS>'>
<dhcp>
<range start='<IP_ADDRESS>' end='<IP_ADDRESS>'/>
</dhcp>
</ip>
</network>
I guess you could understand what is meaning above.Now your VM bridge name is virbbr0…
You can configure networking in many different ways, with nat, with bridging,with simple gateway fowarding… You can find all parameters on the page.
And you can change the definition by using net-edit
.
net-undefine default # forever eliminate the default network
net-define file.xml #to define a new network starting from an .xml file
#you can
virsh ... net-dumpxml default > file.xml
then edit and then
virsh ... net-define file.xml
Starting and stopping networks
net-start default
, to start the named default
network
net-destory default
, to stop the named default
network,with the ability of starting it again in the future.
net-autostart default
, to automatically start the default network at boot.
yubo@debian:~/git$ virsh -c qemu:///system net-start default
Network default started
yubo@debian:~/git$ ps aux | grep libvirt
root 4470 0.0 0.7 1377240 30292 ? Ssl 20:38 0:00 /usr/sbi..
nobody 5155 0.0 0.0 52228 408 ? S 21:40 0:00 /usr/sb..
root 5156 0.0 0.0 52200 408 ? S 21:40 0:00 /usr/sbin/dnsmasq
----------------
yubo@debian:~/git$ sudo netstat -nulp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
udp 0 0 <IP_ADDRESS>:53 <IP_ADDRESS>:* 5155/dnsmasq
udp 0 0 <IP_ADDRESS>:67 <IP_ADDRESS>:* 5155/dnsmasq
-----------------
yubo@debian:~/git$ sudo netstat -ntlp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 <IP_ADDRESS>:53 <IP_ADDRESS>:* LISTEN 5155/dnsmasq
tcp 0 0 <IP_ADDRESS>:22 <IP_ADDRESS>:* LISTEN 546/sshd
libvirt started dnsmasq
, which is a simple dhcp server with ability to also provide DNS.So you can try:
yubo@debian:~/git$ ip address show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet <IP_ADDRESS>/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: enp1s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast
state UP group default qlen 1000
link/ether 94:c6:91:04:e6:91 brd ff:ff:ff:ff:ff:ff
inet <IP_ADDRESS>/24 brd <IP_ADDRESS> scope global dynamic
enp1s0
valid_lft 2670sec preferred_lft 2670sec
inet6 fe80::96c6:91ff:fe04:e691/64 scope link
valid_lft forever preferred_lft forever
3: virbr0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue
state DOWN group default qlen 1000
link/ether 52:54:00:34:36:d3 brd ff:ff:ff:ff:ff:ff
inet <IP_ADDRESS>/24 brd <IP_ADDRESS> scope global virbr0
valid_lft forever preferred_lft forever
4: virbr0-nic: <BROADCAST,MULTICAST> mtu 1500 qdisc pfifo_fast master
virbr0 state DOWN group default qlen 1000
link/ether 52:54:00:34:36:d3 brd ff:ff:ff:ff:ff:ff
you can use iptables to see what happened:
sudo iptables -nvL
&&
sudo iptables -t nat -nvL
Managing storage
Now we have a network running for our VMs,we need to worry about storage.This is similar to lvm, On this post, i just dedicated a directory to storing images and volums.
But, you should mdkir needed dir with
sudo mkdir -p /opt/kvms/pools/devel
and try it:
yubo@debian:~$ virsh -c qemu:///system \
> pool-define-as devel \
> dir --target /opt/kvms/pools/devel
Pool devel defined
Here, we create a pool called devel in a directory , we can see this pool with:
yubo@debian:~$ virsh -c qemu:///system pool-list --all
Name State Autostart
-------------------------------------------
devel inactive no
--all
as before, now we need to start it automatically with command:
yubo@debian:~$ virsh -c qemu:///system pool-autostart devel
Pool devel marked as autostarted
and start it with(must):
yubo@debian:~$ virsh -c qemu:///system pool-start devel
And you can see it again:
yubo@debian:~$ virsh -c qemu:///system pool-list --all
Name State Autostart
-------------------------------------------
devel active yes
To create and manage volumes, you can use vol-create
,vol-delete
,vol-resize
,all the vol-*
can be used.
For examole:
yubo@debian:~$ virsh -c qemu:///system vol-list devel
Name Path
------------------------------------------------------
Installing a virtual machine
With virt-install
yubo@debian:~$ virt-install -n debian-9 --ram 2048 --vcpus=2 \
--cpu=host -c ~/software/debian-9.1.0-amd64-xfce-CD-1.iso \
--os-type=linux --os-variant=debian \
--disk=pool=devel,size=10,format=qcow2 \
-w network=default --graphics=vnc
You must use sudo
command to execute the command,next, you will enter into linux’s installing procession.
-n
just a name.
-c
is your debian-iso where it is located. Remember here, you just define a pool named devel, however, you not have ‘create it’
--disk=pool=devel,size=10,format=qcow2
means it have 10GB space disk to support your VMs.
Managing a vitual machine
This is my first wrong step to try it.I missed it.
After installing VMs, you would better to use virt-viewer
to start it.
Frist,you can start it with virsh:
virsh start my-vms #my vms-name is debian-9 or:
virsh autostart my-vms # debian-9.
So, you type virsh
into virsh’s world.
yubo@debian:~$ sudo virsh
[sudo] yubo 的密码：
Welcome to virsh, the virtualization interactive terminal.
Type: 'help' for help with commands
'quit' to quit
virsh # list
Id Name State
----------------------------------------------------
8 debian-9 running
Remember, you use it with sudo.Here, you can see your vms’s id is 8,
how to start vm with virsh
Again, your vm-id is 8,so next:
sudo virt-viewer --connect qemu:///system 8
Congratulations! Enjoy it:)
后记
For example, when you in trouble reboot the virtual machine,how to do?
In my case, after shutdown the system installed, now i want to reboot,
But, the libvirt warn me: failed to match domain ““.I don’t’ know to do.
Until i have googled: first, use define
to edit the configure file with XML type.Yes, when you installed a system, you will get a XML file in /etc/libvirt/qemu/(or somewhere). My way to slove the problem is cp
the xml file to a directory and then sudo virsh define xx.xml
.If get any errors you can disappear it according to hints.
I will post a new blog to show how to resize the pool size in KVMS.See you!